You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently using Turborepo to manage concurrent runs of two frontend builds, each with its own dev and prod scripts via npm. This setup is part of our strategy to phase out old code while introducing a new stack, keeping our dependencies and coding styles neatly separated.
Both builds employ a fairly typical webpack setup, processing scripts from an assets directory and outputting to a separate dist/static directory, well away from our source files.
Here's the snag: when I run the prod build, Turborepo caches it. Then, if I switch to a dev build, webpack spits out unminified files with source maps into the dist directories. If I revert to the prod build without making any source changes, Turborepo fails to detect any changes—it assumes nothing's new and sticks with the cached build. This means it doesn’t replace the dev files in the static directories with the prod versions.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Summary
I'm currently using Turborepo to manage concurrent runs of two frontend builds, each with its own dev and prod scripts via npm. This setup is part of our strategy to phase out old code while introducing a new stack, keeping our dependencies and coding styles neatly separated.
Both builds employ a fairly typical webpack setup, processing scripts from an assets directory and outputting to a separate dist/static directory, well away from our source files.
Here's the snag: when I run the prod build, Turborepo caches it. Then, if I switch to a dev build, webpack spits out unminified files with source maps into the dist directories. If I revert to the prod build without making any source changes, Turborepo fails to detect any changes—it assumes nothing's new and sticks with the cached build. This means it doesn’t replace the dev files in the static directories with the prod versions.
Additional information
No response
Example
No response
Beta Was this translation helpful? Give feedback.
All reactions