pnpm prune

Удаляет ненужные пакеты.

Опции#

--prod#

Remove the packages specified in devDependencies.

--no-optional#

Remove the packages specified in optionalDependencies.

warning

В настоящее время команда prune не поддерживает рекурсивное выполнение на монорепо. To only install production-dependencies in a monorepo node_modules folders can be deleted and then re-installed with pnpm install --prod.