How to resolve `node:crypto` error during Sveltekit deploy
I've tried creating a
wrangler.toml
file with the node compat config but it doesn't change the outcome.3 Replies
bump
is this a local build or in CI? is node available where you're building? It should work, i have the same stack and im using node:crypto
Solution: Add the
node_compat
flag from within Cloudflares dashboard panel, see screenshot for reference or follow the link: https://developers.cloudflare.com/workers/runtime-apis/nodejs/Cloudflare Docs
Node.js compatibility · Cloudflare Workers docs
Implemented Node.js runtime APIs and enablement instructions for your Worker project.