in my company, PDF generation is a hassle. Our latest approach is to have a single backend service that works asynchronously to PDF generation since the process can take a few minutes.
My suggestion (as a frontend dev myself) to move this operation in a backend server instead of doing this on frontend (is this what you are trying to do at the moment?).
Another solution that I can think of is to "screenshot" the page and turn them into PDF, like the one they do here: https://statically.io/docs/using-screenshot/
github repo: https://github.com/staticallyio/screenshot
I'm using shared hosting currently. I use statically.io's CDN, free WP integration, which is caching on multiple PoP servers (Cloudflare, Cloudfront, Google Cloud, Bunny, and Fastly--also it's supported by Digital Ocean). Before I use statically, my TTFB was always red on webpagetest.org; when using statically, it turns to green on webpagetest.org! But it won't be the only solution for you. Just do your best, or migrate your site to another host.
Hi I saw https://statically.io/ and it seems to work fast and is free. I also looked at Thumbor if it would be worth it to install our own Thumbor. Imgix sewms to have monrhly fee.
Would you know if Magento 2.4 remote storage can accept S3 compatible storage solutions like DigitalOcean Spaces? I couldnt find any article to make Magento 2.4 connect to an s3 compatible storage
Well, hopefully noone is paying more than $5/month for regular hosting!
u/upsetdev knows a lot more about web performance stuff outside my little WP static site cave. Frans runs https://statically.io, also with a "constrained budget" and has a WP plugin for it. If you need a CDN/NodeJS/PHP expert, someone who plays awesome guitar and sings or someone to cook the best Indonesian noodles, say hi~
If you are low on budget, you can try the only true free cdn I came across a few months ago. https://statically.io/wordpress . Apparently its powered by bunny, cloudflare and fastly.