If the html source is already loaded on the frontend why not use html2pdf.js library and build a custom component that generates the pdf on the client side?
I have a good experience with PDF.co (and automate/configure it with Make.com). The PDF.co module can pass parameters in the URL when accessing your Weweb site - obtaining the required dynamic data.
Make.com and PDF.co both require a subscription by the way.