fix(cli): omit heavy devDependencies for local plugins to reduce node_modules size#203
fix(cli): omit heavy devDependencies for local plugins to reduce node_modules size#203singhlovepreet9 wants to merge 2 commits into
Conversation
|
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|



Fixes strapi/strapi#22946
This PR modifies the
sdk-pluginso that when it runs inside a Strapi project (isStrapiProjectis true), it completely omits heavydevDependencieslike@types/react,react-dom,styled-components,typescript,@strapi/design-system,@strapi/iconsetc.These packages are already available in the root of the monorepo workspace for a Strapi project, so they do not need to be duplicated in the local plugin's
devDependencies.This significantly reduces the size of a local plugin's
node_modules(from ~300+MB to a few KB if the user runsnpm installinside the plugin directory), and stops high server memory consumption during builds caused by duplicated module resolution.