When Cloudflare Pages does a deployment, it automatically runs npm clean-install --progress=false
.
However, I need it to run with --legacy-peer-deps
.
Are there any way do define or change build steps with Cloudflare Pages?
When Cloudflare Pages does a deployment, it automatically runs npm clean-install --progress=false
.
However, I need it to run with --legacy-peer-deps
.
Are there any way do define or change build steps with Cloudflare Pages?
Hi @martin57,
Yes, you can define custom build commands in Cloudflare Pages by editing your wrangler.toml
file or specifying the build command in the Cloudflare Pages dashboard under your project settings. Here’s how you can do it:
npm install --legacy-peer-deps && your_build_command
.This will override the default build command with the one you’ve specified.
You can find more information in the following page:
Unfortunately, it didn’t work for me. One step before it still runs Detected the following tools from environment: [email protected], [email protected] Installing project dependencies: npm clean-install --progress=false
Hi @eamagea123 ,
I would recommend asking on Discord if you haven’t already.
For Workers and Pages related topics, our community in there is more active.
Please do feel free to update the thread here if you get a resolution, to help others who may find this topic.
Thanks for using Cloudflare!
I do have the same problem and I hate Discord. It’s way easier to find stuff in the organized topics here. Do we have any updates about this topic?
I’m also facing this issue. Can’t you use the cloudflare build pipeline because of failing legacy peer dependencies. Can we please get a fix for this?