CefSharp
PuppeteerSharp
Our great sponsors
CefSharp | PuppeteerSharp | |
---|---|---|
22 | 16 | |
9,613 | 3,111 | |
0.6% | 2.6% | |
8.4 | 9.2 | |
9 days ago | about 18 hours ago | |
C# | C# | |
GNU General Public License v3.0 or later | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
CefSharp
-
Is there a way to dynamically interpret a string as javascript within a C# winforms program?
I dont want to state the obvious but of course there is CefSharp .. But of course thats pretty heavy duty as you end shipping a headless version of Chrome in your app, but it can do anything a browser can do (of course it can, its Chrome), including exectuting a JavaScript string on the fly and getting a response. Because its Chrome you evenn have access the the dev tool and everything like that. But the other suggestions might be better suited as they might be more lightweight.
-
How do control a browser?
Two options: Either use an embedded browser you can control programmatically like CefSharp (https://cefsharp.github.io/) or spawn a real browser and use sendkeys() to control the browser by emulating user input.
-
Chrome extensions in .NET web view controls
Chrome Runtime discussion in CefSharp repository.
-
Is there something like Electron or Tauri for dotnet?
I always use https://cefsharp.github.io/
- HTMLtoPDF
-
Massive file size 298.2GB
grocy-desktop doesn't do any logging on purpose (CefSharp is the web browser component used).
-
.NET Core ASP - PDF Generation for hosting on Azure?
Haven’t seen anyone suggest this, but an option would be to use https://github.com/cefsharp/CefSharp and basically render some html, open it in chromium and use the print feature. It does a pretty decent job. It may not be a solution for heavy loads, as it was demanding quite a lot of resources for such a “basic” task.
-
Weekly Developer Roundup #23 - Sun Nov 22 2020
cefsharp/CefSharp (C#): .NET (WPF and Windows Forms) bindings for the Chromium Embedded Framework
PuppeteerSharp
-
What do .NET devs use for web scraping these days?
PuppeteerSharp
-
(Free) Open-source PDF Generation/Export
Otherwise, any pdf to hml chromium based solution hosted via docker, like gotenberg](https://github.com/gotenberg/gotenberg) or browserless.io(which is free if you create open source). Generating pdfs from html directly in .NET was always a pain. Wkhtml (and wrappers that use it) uses WebKit and comes with a load of issues of its own, similar to running and styling anything in Safari. Using chromium based engine saves a lot of time as it's the most popular way of doing it these days. You can also use puppeteer-sharp with local chromium if you host your app on something that allows it(f.e. not Azure Functions).
- A Handlebar and Puppeteer Equivalent in C#?
-
Puppeteer Sharp: Crawl the Web using C# and Headless Chrome
Puppeteer Sharp is a port of the popular Headless Chrome NodeJS API built by Google. Puppeteer Sharp was written in C# and released in 2017 by Darío Kondratiuk to offer the same functionality to .NET developers.
-
HTMLtoPDF
For the actual conversion of html to pdf we use PuppeteerSharp (https://www.puppeteersharp.com ) but you need browserless for that, which requires an api key (don’t know the pricing)
-
Dynamic html parser (alternative of phantomJS)
The README in the GitHub site has been good enough for me: https://github.com/hardkoded/puppeteer-sharp
-
QuestPDF 2022.01 - a new version of the open-source, C# library for generating complex PDF documents with fluent API, now with complex table-layout support 🎉 Please help me make it popular 🚀
Iv'e been using https://github.com/hardkoded/puppeteer-sharp for html to pdf conversion for quite some time with success. (in both .net framework and .net core)
-
Last C# PDF doc/tutorial by Microsoft. Tomorrow, the PDF generation feature will be officially retired. So, I took this opportunity to archive this format. (Up to .NET 6)
Just generate HTML and use https://github.com/hardkoded/puppeteer-sharp to produce a PDF from headless Chrome.
-
Playwright (Test Automation Library) for .NET Is Now Stable
Oh, I didn't know this existed. Definitely going to try this. I'm currently using Puppeteer Sharp (https://github.com/hardkoded/puppeteer-sharp) and something like:
> await page.GotoAsync("https://playwright.dev/dotnet");
> await page.ScreenshotAsync(new PageScreenshotOptions() { Path = "screenshot.png" });
Is broken, if you have background images in CSS the screenshot happens after Page Load is completed but before all CSS images are loaded so you end up not getting backgrounds in the screenshot. The only solution is to try add a delay before taking the screen grab, and it there's any sort of latency then the delay could result in not getting a good screenshot...
-
.NET Core ASP - PDF Generation for hosting on Azure?
Just use something like puppeteer in an azure function.
What are some alternatives?
DinkToPdf - C# .NET Core wrapper for wkhtmltopdf library that uses Webkit engine to convert HTML pages to PDF.
playwright-dotnet - .NET version of the Playwright testing and automation library.
ASP.NET Core - ASP.NET Core is a cross-platform .NET framework for building modern cloud-based web applications on Windows, Mac, or Linux.
HtmlAgilityPack - Html Agility Pack (HAP) is a free and open-source HTML parser written in C# to read/write DOM and supports plain XPATH or XSLT. It is a .NET code library that allows you to parse "out of the web" HTML files.
FlaUI - UI automation library for .Net
playwright-sharp - .NET version of the Playwright testing and automation library. [Moved to: https://github.com/microsoft/playwright-dotnet]
puppeteer - Node.js API for Chrome
docker-headless-vnc-container - Collection of Docker images with headless VNC environments
CppSharp - Tools and libraries to glue C/C++ APIs to high-level languages
PythonNet - Python for .NET is a package that gives Python programmers nearly seamless integration with the .NET Common Language Runtime (CLR) and provides a powerful application scripting tool for .NET developers.
GotenbergSharpApiClient - .NET C# Client for the Gotenberg API