yarn remove
yarn remove <package...>
正在运行yarn remove foo将删除您的直接依赖项中指定的程序包foo,用于更新过程中的文件package.json和yarn.lock文件。
其他开发该项目的开发人员可以运行yarn install同步他们自己的node_modules目录和更新后的一组依赖项。
当你删除一个包时,它是从所有类型的依赖关系删除dependencies,devDependencies等。
Note:
yarn removewill always update yourpackage.jsonandyarn.lock. This ensures that different developers on the same project get the same set of dependencies. It is not possible to disable this behavior. Note:yarn remove <package> --<flag>uses the sameflags asyarn installcommand.
本文档系腾讯云开发者社区成员共同维护,如有问题请联系 cloudcommunity@tencent.com

