del-nm
Delete
node_modules
and lockfiles
Useful to perform fresh installation of dependencies.
Installation
npm install --save del-nm
Usage
$ tree.├── bar│ ├── node_modules│ └── yarn.lock└── foo ├── node_modules └── package-lock.json
const delNm = ; ; ; ;
API
delNm([options])
Returns Promise<Array>
of deleted paths.
options
Type: Object
cwd
Type: string
Default: process.cwd()
Current working directory.
lockfiles
Type: boolean
Default: true
Set this to false
to not delete lockfiles. Remember that npm-shrinkwrap.json
will also be deleted when this option is set to true
.
Related
- del-nm-cli - CLI for this module
- force-del - Force delete files or folders using glob patterns
- remove-lockfiles - Prevent committing lockfiles
License
MIT © Lufty Wiranda