Clown Studios
Clown Studios
CDCloudflare Developers
Created by DrKayBee on 10/9/2024 in #pages-help
Unable to override build settings when deploying
changing the build command to npm install --force && npm run build might not work if the settings are cached or not properly applied. try clearing the cache or rechecking the settings in cloudflare pages. using npx wrangler pages deploy works but breaks git integration, and git actions are a bit heavy just to override a build command. you could also try adding a .npmrc file to manage npm install --force directly without needing to override the entire build command.
3 replies
CDCloudflare Developers
Created by ericmatthys. on 10/9/2024 in #pages-help
How best to use jsx / tsx entry point with `cloudflare pages dev`
sounds like you're running into a parsing issue with jsx in cloudflare pages functions. since miniflare doesn't support jsx out of the box, you could try adding a build step using esbuild or another lightweight bundler to transform your jsx into plain js before running it with cloudflare pages dev. unfortunately, without vite or webpack, there's no built-in way to handle jsx directly in that environment. it seems like wrangler pages functions build can handle it because it's doing the transformation for you. you could try setting up a basic esbuild config to transpile the jsx before running your dev server.
2 replies
CDCloudflare Developers
Created by anand248 on 10/13/2024 in #workers-help
Which library do you use to generate pdf at worker side?
i'd recommend using pdf-lib or pdfkit for generating PDFs on the worker side. they tend to be more compatible. if you're getting module errors with jspdf or pdfmake, those libraries might not work well in that environment.
2 replies