The Free Way to Create Awesome PDFs in .NET

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ธ.ค. 2024

ความคิดเห็น • 262

  • @irezax
    @irezax 3 หลายเดือนก่อน +63

    Keep in mind this will be pretty memory intensive though. For real production environments you will need something light that can also scale well. Consider using a pure library for real world scenarios.

    • @peepeefrog_
      @peepeefrog_ 3 หลายเดือนก่อน +12

      We are not generating PDFs in a O^2 cycle

    • @leonardoperes-so1nc
      @leonardoperes-so1nc 3 หลายเดือนก่อน +2

      Can you suggest me one?

    • @prman9984
      @prman9984 3 หลายเดือนก่อน +5

      This is exactly what I was thinking. This is VERY heavy.

    • @Washbancz
      @Washbancz 3 หลายเดือนก่อน +1

      ​@@leonardoperes-so1nc I'm commenting here to get notified

    • @vexxxG
      @vexxxG 3 หลายเดือนก่อน +4

      Since this and puppeteer load chromium it is memory intensive, but if you use it as a singleton and just instantiate playwrite once then it should be fine. But as soon as you want pdfs that are editable, contain fields or you need digital signature capability, yeah this is not gonna cut it at all, and that is when you will start paying a lot of money for a bigger library (syncfusion has one of the best licensing as far as I can tell since the community version gives you a free license until you hit like a 2million $ profit margin or something like that)

  • @Siddiskongen
    @Siddiskongen 3 หลายเดือนก่อน +69

    No library. installed playwright ....

  • @catalindanciu1212
    @catalindanciu1212 3 หลายเดือนก่อน +2

    Thank you for sharing this relatively simple trick Nick. Here's how I do it whenever business requires pdfs: I just tell them to prepare the templates as excel or word documents and then proceed to use NPOI to populate the data, and after that use LibreOffice headless (sofice executable) to convert to pdf. It's not the fastest or most accurate (especially if you have intricate formatting documents), but hey...it's free and it also works on Linux.

  • @xakzpc
    @xakzpc 3 หลายเดือนก่อน +4

    wow, amazing timing, I just explored ways to create pdfs literally yesterday

  • @chrisbaker5284
    @chrisbaker5284 3 หลายเดือนก่อน +6

    I use the built in PrintDocument() set its PrinterSettings object to use Microsoft Print to PDF driver (this does have the drawback of creating a temporary file though). Setting up the page is a bit tricker than using html converters, but easy enough and I have complete control of the whole process.

  • @TheCodeCreator
    @TheCodeCreator 3 หลายเดือนก่อน +2

    Well, doesn't matter what I was using. I will start using this approach in small and simple projects from now on. Amazing! Thanks for sharing.

  • @frankroos1167
    @frankroos1167 3 หลายเดือนก่อน +1

    I have been looking for this for a while. Mainly for toying around and make a POC for some things that my boss won't ok, until he has a POC.
    Chances are it will even be enough for what we want to do. So if I say "Hey, no library to pay for", he'll be happy. Although, if we do end up needing a library that isn't too expensive, I can probably convince him, with some good arguments added to the POC.
    Thank you so much for pointing me in a feasable direction.

  • @modulsyd9222
    @modulsyd9222 3 หลายเดือนก่อน +11

    I have usel Blazor for years to create nice prints, also with pagination and booklet printing 😊

  • @JustDezz
    @JustDezz 3 หลายเดือนก่อน +110

    > No libraries, no nothing
    > Installs a bunch of packages

    • @qj0n
      @qj0n 3 หลายเดือนก่อน +18

      ...runs a script to install browser binaries on the machine

    • @mrx10001
      @mrx10001 3 หลายเดือนก่อน +7

      ye should change it to no paid libraries.

    • @jeremymartini1975
      @jeremymartini1975 3 หลายเดือนก่อน

      @@mrx10001 And so he did

    • @justinian.erdmier
      @justinian.erdmier 2 หลายเดือนก่อน +8

      I mean, the whole point of .NET Core was to break it up into a bunch of smaller packages instead of one giant library. Everything he installed was from Microsoft. It was pretty clear, as he kept mentioning IronPDF, that he meant third party libraries, and specifically ones that require a paid license.

    • @metalor696
      @metalor696 หลายเดือนก่อน

      @@justinian.erdmier "I meeeeeannn"

  • @iiTzluffy
    @iiTzluffy 3 หลายเดือนก่อน +9

    For all the haters, the title is "The Free Way to Create Awesome PDFs in .NET". All of you should be thankful he created such video. You noobs.

    • @holger_p
      @holger_p 2 หลายเดือนก่อน

      Not any criticism is hate. And his idea is only suitable for web-projects. Not for Backend applications.

  • @haukurorsson833
    @haukurorsson833 3 หลายเดือนก่อน +3

    Not sure I like using Chromium to do this, but using the Razor engine to render components/models into HTML strings is brilliant, I did not think of that. I'm already creating PDFs from manually constructed HTML strings using SelectPdf. I might incorporate the Razor engine for templating. Thanks!

  • @PietervandenHombergh
    @PietervandenHombergh 3 หลายเดือนก่อน +12

    I have good experience using latex. Your code generates latex code, possibly using templates and then run a pdflatdx compiler as a sub process.

    • @michallevy9806
      @michallevy9806 3 หลายเดือนก่อน

      Yep. I use a similar approach - generating XSL-FO from templates and running Apache FOP to do the conversion to PDF

    • @tymurgubayev4840
      @tymurgubayev4840 3 หลายเดือนก่อน

      Just wondering: did you consider using LuaTex? And if you did, what was you conclusion?

  • @WahidBitar
    @WahidBitar 3 หลายเดือนก่อน +1

    we're using puppeteer to call our frontend page by passing the access token in the query string.
    the advantage we have is the frontend team design the required document using the tools they already familiar with
    the disadvantages is the complex setup and depending on the server to have chromium and so on

  • @rodrigo6459
    @rodrigo6459 3 หลายเดือนก่อน +2

    This was GREAT!! Just in time for exactly this requirement for a project I’m working on!! 👍👍

  • @wsidechris
    @wsidechris 3 หลายเดือนก่อน +2

    If you need a proper publishing infrastructure (page layouts, footnotes, overflow options), then I’ve used XSLFO for years. Similar to HTML markup with CSS. I use a simple paid library called Ibex to render it.

  • @sonicmouse3083
    @sonicmouse3083 3 หลายเดือนก่อน +114

    All these "HTML To PDF" libraries suck. They all package the Blink/Chrome browser in the nuget package, so it's huge. They use the "print to pdf" implemented by blink. Needless to say, it is extremely memory and CPU intensive. Most of us will need to create thousands if not hundreds of thousands of PDFs -- This library will bring your entire server to a crawl, and you'll be paying out the you-know-what in CPU usage. Just buy a real PDF library. The cost will be a wash. Yes, this is a free alternative to these libraries, but that will be the least of your problems if you need to do real work.

    • @gahshunker
      @gahshunker 3 หลายเดือนก่อน +9

      At this point, just run a cmd comand to use msedge print-to-pdf functionality, just serve your html to it and that’s it. Msedge comes default with windows, so no other dependencies needed.

    • @CesarDemi81
      @CesarDemi81 3 หลายเดือนก่อน +7

      I was coming to say the same: at my work we had to evaluate different libs (both free and paid) and ended up deciding for QuestPdf because it was way simpler and much better performant than any of these BS html-to-pdf libs that have all the cons you mentioned. We evaluated Playwright and IronPdf as well and both ended up in the trash can.
      At some point companies have to decide to spend some money and in the context of big projects, it really is not worthy to cut down expenses on these things which can really have an impact.

    • @BamYazi
      @BamYazi 3 หลายเดือนก่อน +1

      @@CesarDemi81 This is almost the solution i ended up with - I use Xceed Words to generate a document (i also need to be able to save out a Word version of the PDF), use WebView2 (Edge but really Chromium under the hood) to preview the PDF in the (desktop) app - which you get for free, and then have a SaveAs word function - I have yet to find a nice solution to this - even with expensive paid libraries there always seems to be some 'hacking' involved to have a nice document output functionality

    • @jcarman
      @jcarman 3 หลายเดือนก่อน

      ASPOSE & ABCPDF, I'm looking at you. Such ridiculously large libraries for what they do...

    • @Feeder-fi5dh
      @Feeder-fi5dh 3 หลายเดือนก่อน +3

      If you want good looking, easy to maintain PDFs, using HTML templates is an excellent approach. But you will always need a browser engine if you want to use the latest CSS possibilities.

  • @Maestrou-jb1rq
    @Maestrou-jb1rq 3 หลายเดือนก่อน +6

    Very nice solution to render PDFs! This should also work with Selenium instead of Playwright

  • @maskettaman1488
    @maskettaman1488 3 หลายเดือนก่อน

    If only printing were this easy! Great video as always

  • @KnightSwordAG
    @KnightSwordAG 3 หลายเดือนก่อน +9

    Wouldn't it be just as sensible to use the MVC Razor page render engine? Aren't they ultimately the same thing?

  • @GoldenPockets2
    @GoldenPockets2 2 หลายเดือนก่อน

    I had to develop a project with PDF reports, and what I did is, I created a TeX template with labels like __name__, __date__, etc. So those labels were replaced with code and the result was converted to PDF. I even included some graphs with TeX libraries.
    The final software had to bundle the TeX distribution (MiKTeX if I recall correctly).

  • @CuriouslyContent
    @CuriouslyContent 3 หลายเดือนก่อน +5

    A lot of people are commenting that this would crush server performance and/or cost a ton of money. That assumes the reports are being generated on the server and that you are in the cloud. In some scenarios that is unavoidable. But many other scenarios this solution would work well.
    For Desktop apps, this would be great (can everything Nick did can be baked into the desktop app and just send the data to the client and have them render it?).
    With the web, well, you are already rendering to HTML, so you can just have the client export to pdf from his/her browser.
    So really the only scenario where this would be an issue is if you were a company offering a pdf-generating service to clients. Then you do have the possibility of millions of pdfs being generated in a short amount of time (if you have a large client base). But if you are a company generating invoices for your clients in-house, then this would absolutely be a viable solution.

    • @NikaTark
      @NikaTark หลายเดือนก่อน +1

      The point of PDFs is that you can lock editing and sign it, which is crucial for invoices or other legal documents.
      You lose that when you ask client to export the html page to a pdf, them being free to edit any fields before doing so.

  • @KvapuJanjalia
    @KvapuJanjalia 3 หลายเดือนก่อน +29

    Headless Chromium? No, thanks. Not on my servers.

    • @burtonrodman
      @burtonrodman 3 หลายเดือนก่อน +9

      put it in a purpose built container that has NOTHING else running there.

  • @gabynevada
    @gabynevada 3 หลายเดือนก่อน +2

    Packaged the same approach in the BlazorReports library, but more for a separate report server.
    This approach works great as you can leverage Blazor and other Js libraries.

    • @theCybertier
      @theCybertier 3 หลายเดือนก่อน +1

      Do you have any experience how this approach deals with header/footer logic, especially one time headers followed by a different repeating header? Same for footers? Also tables across multiple pages with and without their own repeating header? Those were topics previous approaches I saw to PDF generation from HTML struggled with.

    • @gabynevada
      @gabynevada 3 หลายเดือนก่อน

      @@theCybertier It's definitely a limitation, it's not hard to include repeating headers or footers but when you need to add logic to them it gets harder. Will try to see if I can get a usable example on the repo if it's viable.

  • @jeremiahtatro4456
    @jeremiahtatro4456 3 หลายเดือนก่อน

    I used to use Office apps to print to a Postscript file, then had a script that would package the Postscripts as a PDF. It was free, in that my employer used Office for everything but printing to Postscripts isn't exclusive to Microsoft products and is completely free as long as you have a Postscript printer installed.

  • @canabale
    @canabale 3 หลายเดือนก่อน +1

    Hey Nick,
    I love your videos and I'd have a wish on a topic.
    Could you please make a video about best practices on pull-requests, focussing not on the self-explanatory branch policies, but more on the perspectives of author and reviewer?
    Reason:
    We had a couple of "fights" in our company because of comments on pull-requests.
    We had these issues on multiple products, involving multiple developers and I feel like it's a systematic issue that must be addressed, before things get out of hand. I highly doubt that we are the only ones struggling with this, since pull-requests are a devops essential.
    And I am pretty sure, that someone like you, with an own "code-cop" series, has some neat hints on how to improve as both, author and reviewer, to keep such things from happening. And even if not, it would be great if you could share your experiences with this, cause then this community will very likely be able to provide decent advice.

  • @matthewsheeran
    @matthewsheeran 3 หลายเดือนก่อน +1

    A smart alternative would be to communicate instead with, and print on, the client side with the user's browser! Equals no server side bloat or CPU.

  • @WarrenGarabrandt
    @WarrenGarabrandt 3 หลายเดือนก่อน

    I was JUST looking for something like this!

  • @dom4068
    @dom4068 3 หลายเดือนก่อน

    Having worked on creating pdf muliple times, the way we had done without pdf library was when the content was created in our appliction.
    If we have conver a content created by another application, that is challenging. And the PDF library based on browsers seems to be the only way. The main reason being bowsers allow lot of errors in html.
    The best way to extend the capability was to use a flow document to have the ability to fixed documet and then to pdf, which unfortunately Ms choose not to do.
    Another prospective way is to extend the print to pdf, which also can be done to a good extent, but the libraries that i explored had one issue or another.

  • @DanielRezendePessoa
    @DanielRezendePessoa 2 หลายเดือนก่อน

    Awesome!!! Save my life!!! Thank You!!!

  • @themikeporter
    @themikeporter 3 หลายเดือนก่อน

    Nice, I like it. On desktop apps, I use WPF with Xaml in code to print to the Microsoft PDF driver. I've created some very complicated products with drawing and graphing with complete pagination.

  • @TheSilent333
    @TheSilent333 3 หลายเดือนก่อน +12

    I love things like this. Definitely saving this in case I need to create any PDFs. Getting my employer to shell out money for libraries is next to impossible :P

  • @StephenMoreira
    @StephenMoreira 3 หลายเดือนก่อน

    Very interesting. Will check it out for my project.

  • @binino7684
    @binino7684 28 วันที่ผ่านมา

    I wish I knew this about 3 years ago 🤣
    Next time I'll do it like this, but I will isolate it as a service in a container and send to an storage like s3

  • @agmiddles
    @agmiddles 3 หลายเดือนก่อน

    This was a great and creative solution.

  • @DanteDeRuwe
    @DanteDeRuwe 3 หลายเดือนก่อน

    This is actually a very interesting approach to be able to do SSG with Blazor! Experimented with it before and although it's rudimentary; it does the trick. I did not think of the use case of creating pdfs though, very interesting!

  • @stevenj8261
    @stevenj8261 3 หลายเดือนก่อน +2

    Using gotenberg
    Container able to do html to pdf or word to pdf using libre Office

  • @sergeyz.5845
    @sergeyz.5845 3 หลายเดือนก่อน +11

    Let's do the no external libraries app challenge!

  • @kamau6988
    @kamau6988 3 หลายเดือนก่อน

    Very timely video

  • @stati5tik
    @stati5tik 3 หลายเดือนก่อน +2

    Nice, now show the memory consumption.

  • @BamYazi
    @BamYazi 3 หลายเดือนก่อน

    This is a pretty cool solution (i love using the Razor html renderer in a non browser app - already got me thinking of other uses for that), although this solution is also pretty 'expensive' because of the dependency on Playwright which means including Chromium etc which are pretty large dependencies. Personally i use Xceed Words to generate documents Word/PDF which isn't as nice in terms of the code needed to create the document, but a bit more lightweight (and very cheap compared to most of the paid document generation libraries).

  • @lacuevadelinsecto
    @lacuevadelinsecto 3 หลายเดือนก่อน +1

    I really like this approach. I wonder if there is a way to generate the PDF using streams. For example, when there is a large amount of data that requires writing the file while the data arrives. Also, when there are many files queued to be generated.

  • @dukefleed9525
    @dukefleed9525 3 หลายเดือนก่อน +3

    PupeteerSharp also allows to detect and fine control which version of browser is installed

  • @techwatching
    @techwatching 3 หลายเดือนก่อน

    I like the open source library Quest PDF (there is a commercial licence also, but the price is okay).

  • @TreeLuvBurdpu
    @TreeLuvBurdpu 2 หลายเดือนก่อน

    I use Pandoc. You can also call it from the CLI.

  • @Kingside88
    @Kingside88 3 หลายเดือนก่อน

    Man this is amazing.
    I still love the good old way using rdlc to generate pdfs.
    But I guess this way is also kind of ok

  • @AslamNazeerShaikh
    @AslamNazeerShaikh 3 หลายเดือนก่อน +3

    Please make more PDF manipulation videos

  • @_MoshikoAz_
    @_MoshikoAz_ 3 หลายเดือนก่อน +1

    will it work as a service for web api controller ?

  • @AbuBakrSadiqi-b7t
    @AbuBakrSadiqi-b7t 25 วันที่ผ่านมา

    Hello, very information video, I have one question. please answer my question
    I have a microservices architecture with 5 services, 2 of them send emails, so have different html dynamic templates in email, and other three have pdfs, .. So if i create a 6th service of blazor project, and then send requests from other services to blazor to create pdf or html (as you are showing on video), and then can download or send on email. is that a good practice? I mean at the same time blazor will be responsible for creating email template like password reset email or otp email, and also responsible as a service to send emails and print pdfs.

  • @Shenron666
    @Shenron666 2 หลายเดือนก่อน +2

    You said "no libraries", so how do you call Playwright if not a library ?

  • @robadobdob
    @robadobdob 3 หลายเดือนก่อน

    We currently use the Syncfusion library. It does the job but I have been tempted to pivot to Playwright to save $$$.
    The thing I can’t see this approach doing is document assembly i.e. taking multiple PDF and merging them into one PDF with page numbering etc.

  • @samuelschwager
    @samuelschwager 3 หลายเดือนก่อน

    nice clean solution

  • @code8986
    @code8986 3 หลายเดือนก่อน +3

    Some years ago I used PDFlib to generate PDFs based on a template document and dynamically populated field values.
    I think it was a fairly expensive library and probably overkill in many cases, but it worked flawlessly, was extremely scalable, and could do pretty much anything with PDF files.

  • @microtech2448
    @microtech2448 3 หลายเดือนก่อน +3

    Will this work on azure app service?

    • @umair_me
      @umair_me 3 หลายเดือนก่อน

      This is my question too. if anyone has tried let us know?

    • @KhaUh
      @KhaUh 2 หลายเดือนก่อน

      @@umair_me i had someone said to me that it would work but i never tried it

  • @awright18
    @awright18 3 หลายเดือนก่อน

    Regardless of the implementation, I really like the idea of generating PDFs from HTML because average developers can do it.

  • @maxsnts
    @maxsnts 3 หลายเดือนก่อน +2

    I/we did the same but instead of having that in the app, i did an API, you sent it a link (of the invoice) and the API returns the pdf. No overhead of installing playright/chromium on all servers, just the ones dedicated to this api

  • @Kirill-l7c9y
    @Kirill-l7c9y 3 หลายเดือนก่อน

    WOW! Realy cool. I am afraid that IronPdf has ordered you after it

  • @marna_li
    @marna_li 3 หลายเดือนก่อน

    I have used libraries that allow me to dynamically compile a template (int Razor syntax) that I had fetched from the database. I wanted to move over to the Razor components engine but since it lacks that support it is impossible. You kind of have to compile the templates into the project. Unless you compile components into a separate assembly, store it somewhere, and then load it when you generate the invoice.

  • @Mr767267
    @Mr767267 2 หลายเดือนก่อน

    Thanks for sharing. Does it have capability to protect PDF, sign PDF too?

  • @rupture007
    @rupture007 3 หลายเดือนก่อน

    I use just html file with scriban for templating to replace the placeholders. Then IronPDF for the pdf generation. It works well, but I want to try this now.

    • @rupture007
      @rupture007 3 หลายเดือนก่อน

      seems like it would be easy for me to swap out IronPDF and try this since I already have a string for the html that I pass to IronPDF. I'll report back if it works. The html has chartjs-umd in it and some data points to make some charts. Should be interesting to see if that works with Playwright

  • @TewodrosAAssefa
    @TewodrosAAssefa 3 หลายเดือนก่อน +5

    What is the resource usage like?

    • @gabynevada
      @gabynevada 3 หลายเดือนก่อน +5

      @@TewodrosAAssefa you can make it pretty efficient by skipping play right and controlling the chrome instances directly.
      You can make it so that you stream the report from the chrome instance to the Response body without having to buffer the entire pdf in memory using pipes.
      Been generating tens of thousands of reports daily on a container with 1 vCPU AND 1GB of RAM.

    • @ВладиславДараган-ш3ф
      @ВладиславДараган-ш3ф 3 หลายเดือนก่อน +2

      @@gabynevadait’s still freaking Chrome dude, it’s a horrible idea

    • @marcelfiechter7436
      @marcelfiechter7436 3 หลายเดือนก่อน

      @@gabynevada This sounds great. I try to find out how this works. I save the Chromium binaries on my device. Then I probably start with ChromiumDirectory = "C:\Users\Me\DotNetBrowser" and create the EngineFactory. What is the key-line to get the pdf finally in the Response body?

    • @gabynevada
      @gabynevada 3 หลายเดือนก่อน

      @@ВладиславДараган-ш3ф right now other forms of generating PDFs are very limited, if you need the flexibility then a browser is one of the best ways to do it.
      Hopefully other options will keep growing and we can avoid it in the future.

    • @marcelfiechter7436
      @marcelfiechter7436 3 หลายเดือนก่อน +1

      @@gabynevada That sounds great. But I don't understand where the conversion to pdf is?

  • @PratikPanchal-tp8dp
    @PratikPanchal-tp8dp 2 หลายเดือนก่อน

    Awesome !!!

  • @varmelot
    @varmelot 2 หลายเดือนก่อน

    Paid PDF libraries is not only about create PDF document. It's about manipulate Signatures and aForm data

  • @vbachris
    @vbachris 3 หลายเดือนก่อน

    i did something like this a few years ago for email templates

  • @davidepotocnik4838
    @davidepotocnik4838 3 หลายเดือนก่อน +2

    Hey....but in the containerized era there is the Gotenberg

    • @DClearEE
      @DClearEE 2 หลายเดือนก่อน

      Playwrite and gotenberg both look like they use headless chromium to create PDFs. You just containerize playwrite and have it basically be the same thing

  • @sodreigor
    @sodreigor 3 หลายเดือนก่อน

    Hey Nick did you ever have to read pdfs programmatically? Which lib did you use in that case?

  • @Zhum22
    @Zhum22 3 หลายเดือนก่อน +1

    Very nice! But do you have to install the browser on the computer for this to work?

  • @thebrandseagle
    @thebrandseagle 3 หลายเดือนก่อน

    Can we do similar in a blazor web assembly application?

  • @RicusNortje
    @RicusNortje 3 หลายเดือนก่อน

    I still live JS Report. Can slef host and get 5 free templates which can be more than enough if used cleverly

  • @vernonjacobs7140
    @vernonjacobs7140 3 หลายเดือนก่อน

    @nick does this work with something like bootstrap,etc

  • @sunindragupta9236
    @sunindragupta9236 2 หลายเดือนก่อน

    Hi Nick, trying to convert a Html to pdf. When done via Chrome browser it's perfect, all the images and page breaks are perfect, I need to do it via azure function, please advise

  • @eyu6652
    @eyu6652 3 หลายเดือนก่อน

    Question. Can you include tailwindcss or bootstrap css?

  • @alexclark6777
    @alexclark6777 3 หลายเดือนก่อน

    "Here's something I prepared earlier" - shout out to the Blue Peter fans.

  • @burakkoprulu3504
    @burakkoprulu3504 11 วันที่ผ่านมา

    I can not see local image on pdf? did I do something wrong

  • @MatinDevs
    @MatinDevs 3 หลายเดือนก่อน

    9:09 Nick just violated Apple

    • @deado7282
      @deado7282 3 หลายเดือนก่อน

      No, he violated Safari. Because it's just the worst piece of sh**.

  • @Rajeshsingh-ws5th
    @Rajeshsingh-ws5th 3 หลายเดือนก่อน

    HTML to pdf is good for just learning and basic PDF file. need to do lot of changes when it comes to create slightly complex document.

  • @santiagocalgaro2486
    @santiagocalgaro2486 3 หลายเดือนก่อน +3

    I had a really hard time containerizing libraries that convert HTML code to PDF because they usually rely on Windows packages. Can this one run on Linux?

    • @goldfinger490
      @goldfinger490 3 หลายเดือนก่อน +2

      yes

    • @JohanBenschop
      @JohanBenschop 3 หลายเดือนก่อน +1

      We have done a very similar thing to Nick's shown here, and it has been running in production for a while now on the smallest Linux Azure Container App they have.

  • @prashantmahajan8584
    @prashantmahajan8584 หลายเดือนก่อน

    Can we create pdf/a through this?

  • @StackMJ
    @StackMJ 2 หลายเดือนก่อน

    How fast is it in comparison to Rotativa?

  • @nickw656
    @nickw656 2 หลายเดือนก่อน

    will the code be run on Linux without GUI?

  • @joga_bonito_aro
    @joga_bonito_aro 3 หลายเดือนก่อน

    That is friendly awesome.

  • @Alguem387
    @Alguem387 3 หลายเดือนก่อน

    Reminds me of the time i serializeda object to json to then transform said json into xml becuase the xml library did not support DateOnly and TimeOnly structs

  • @therealhidayah
    @therealhidayah 3 หลายเดือนก่อน

    Geat work

  • @coreysteinwand
    @coreysteinwand 3 หลายเดือนก่อน +3

    This is cool, I wonder if we can use this library for qr codes / barcodes for a label printer

  • @Coco3l
    @Coco3l 3 หลายเดือนก่อน

    Somebody was on vacation 🏖🏖🏖

  • @faisalalhoqani6151
    @faisalalhoqani6151 2 หลายเดือนก่อน

    In my case, I am using RDL through the .NET Framework API to get PDF or Excel for my .NET Core application.

  • @AtikBayraktar
    @AtikBayraktar 3 หลายเดือนก่อน

    that's clever!

  • @eglauko
    @eglauko 3 หลายเดือนก่อน

    Very cool

  • @andersborum9267
    @andersborum9267 3 หลายเดือนก่อน +1

    Are the PDFs UA compatible?

    • @stephanf17
      @stephanf17 3 หลายเดือนก่อน

      ^^ + I am always missing an option to add a data layer (as you'd need to create most of eInvoice formats).

  • @hipihypnoctice
    @hipihypnoctice 3 หลายเดือนก่อน +3

    Idk I think quest pdf is still nicer
    Edit: after Nick pointed out that QuestPDF is no longer FOSS then yeah this is nicer

    • @joaogabrielv.m328
      @joaogabrielv.m328 3 หลายเดือนก่อน

      Same... Easy to use and highly customizable

    • @axelgenus
      @axelgenus 3 หลายเดือนก่อน

      Well, keeping HTML templates of documents can be way easier than keeping code. Also, there are many templating engines for HTML.

    • @nickchapsas
      @nickchapsas  3 หลายเดือนก่อน +6

      It’s a completely different approach to making PDFs and it’s not free

    • @hipihypnoctice
      @hipihypnoctice 3 หลายเดือนก่อน

      @@nickchapsas did they change it I could've swore it was under a open source license without restrictions.
      Edit: wow they did change it. Nvm I understand the need now

    • @hipihypnoctice
      @hipihypnoctice 3 หลายเดือนก่อน

      @@axelgenus I've used quest pdf for a real project for a large automotive company for accounting purposes. So I think it's just preference

  • @LouisDuran
    @LouisDuran 3 หลายเดือนก่อน +1

    Weird on the timing of this.... I was just adding save to PDF support in a WPF application I'm developing for a client. Unfortunately I can't see a way to integrate this solution into a WPF application.

    • @coloresfelices7
      @coloresfelices7 3 หลายเดือนก่อน +1

      In a WPF application I developed years ago, I created XPS files and called GhostScript to convert them to PDF. Has the advantage that, for creating XPS, I can re-use all WPF UI components.

    • @LouisDuran
      @LouisDuran 3 หลายเดือนก่อน

      @@coloresfelices7 ok. I'm sort of doing the same. Rendering WPF Visual element into XPS format, then using PDFSharp to convert that to PDF. The problem is the Visual element is a scroll viewer and I want to have it render the entire content not just what's visible. I need to do more research...

  • @alissoncandatem1896
    @alissoncandatem1896 3 หลายเดือนก่อน

    I need to digitally sign PDFs, but I'm not sure where to begin or even if it's possible to do that with this but i'll give it a try

    • @sarcasticMoose
      @sarcasticMoose 3 หลายเดือนก่อน

      Firstly you have to get a certificate (need to buy it) and the signing tool.

    • @alissoncandatem1896
      @alissoncandatem1896 3 หลายเดือนก่อน

      @@sarcasticMoose I do own a certificate and can technically sign it I just need to add it visually into the pdf itself.

  • @EminoMeneko
    @EminoMeneko 3 หลายเดือนก่อน

    If only I knew that 5 years ago... :')

  • @JustinChasez04121990
    @JustinChasez04121990 3 หลายเดือนก่อน

    Would love to see if you can Dockerize this solution. I have tried and it failed. Maybe I did something wrong?

  • @sulmarpl
    @sulmarpl 3 หลายเดือนก่อน

    Can this generation method be used on a docker?

    • @sakesun
      @sakesun 3 หลายเดือนก่อน +1

      You will have to use Debian based image as required by Playwright. Other Linux is not supported by default.

    • @sulmarpl
      @sulmarpl 3 หลายเดือนก่อน

      @@sakesun Thank you for hint. I found a image linuxserver/chromium.

  • @sergeynosov8180
    @sergeynosov8180 3 หลายเดือนก่อน +3

    The other problem with HTML to PDF is pixel-perfect rendering for intricate work (such as exact positioning on pre-cut labels) and bleeds. You do not always need pixel-perfect rendering, but when you do, HTML just does not cut it.

  • @piotrmilotrojan
    @piotrmilotrojan 3 หลายเดือนก่อน +2

    Does this work in no GUI environments? Like VPS or some Bash only linux installation?

    • @nickchapsas
      @nickchapsas  3 หลายเดือนก่อน +1

      Yeah ofc

  • @arjunmenon2901
    @arjunmenon2901 3 หลายเดือนก่อน

    What is your take on IronPdf ?

    • @adds-kz3oc
      @adds-kz3oc 3 หลายเดือนก่อน +4

      It's paid.

    • @arjunmenon2901
      @arjunmenon2901 3 หลายเดือนก่อน

      @@adds-kz3oc oh yeah. We have perf issue with ironPDF in Linux servers. Have been searching for an alternative solution.

  • @davidjackson148
    @davidjackson148 3 หลายเดือนก่อน

    first question, why do i need blazor?

    • @raduban2029
      @raduban2029 3 หลายเดือนก่อน

      You don't. You just need a way to use the Razor view engine to generate HTML as a string from Razor views. It works equally well with MVC, I've been using it for 10+ years in production with the IBEX xsl-fo processor (paid for, equivalent to Apache fop)

    • @davidjackson148
      @davidjackson148 3 หลายเดือนก่อน

      @@raduban2029 just wondered why it was in there if you don't need it, just seems to complicating a simple concept for the sake of it

  • @djupstaten2328
    @djupstaten2328 3 หลายเดือนก่อน

    What would happen if I use just any html as my HtmlString and run it through Playwrite and PdfAsync ?

    • @jeffreykleine871
      @jeffreykleine871 3 หลายเดือนก่อน

      The same, it will just render the html through chromium and use it's pdf function.

  • @mottahh4162
    @mottahh4162 3 หลายเดือนก่อน

    I was in the save as pdf camp until this