yarn clean

yarn clean

Cleans and removes unnecessary files from package dependencies.

yarn clean

The clean command frees up space by removing unnecessary files and folders from dependencies. It reduces the number of files in your project’s node_modules folder which is useful in an environment where packages are checked into version control directly.

Once you run yarn clean, Yarn will create a .yarnclean file that should be added to version control. Cleaning is then automatically done as part of yarn install (or simply yarn) and yarn add.

Note: This command is considered for advanced use cases only. Unless you are experiencing issues with the amount of files that are installed as part of node_modules it is not recommended to use this command. It uses a heuristic to identify files that may not be needed from a distributed package and may not be entirely safe.

© 2016–2017 Yarn Contributors
Licensed under the BSD License.
https://yarnpkg.com/en/docs/cli/clean

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部