https://github.com/chrisdothtml/ls-installed-deps
Recursively gathers names and versions of installed dependencies
https://github.com/chrisdothtml/ls-installed-deps
avajs dependencies nodejs
Last synced: 2 months ago
JSON representation
Recursively gathers names and versions of installed dependencies
- Host: GitHub
- URL: https://github.com/chrisdothtml/ls-installed-deps
- Owner: chrisdothtml
- License: mit
- Created: 2019-01-16T23:57:43.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-17T00:29:57.000Z (over 7 years ago)
- Last Synced: 2025-09-13T14:01:25.813Z (10 months ago)
- Topics: avajs, dependencies, nodejs
- Language: JavaScript
- Homepage: https://npm.im/ls-installed-deps
- Size: 73.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# ls-installed-deps
[](https://standardjs.com)
[](https://travis-ci.org/chrisdothtml/ls-installed-deps)
[](https://coveralls.io/github/chrisdothtml/ls-installed-deps)
> Recursively gathers names and versions of installed dependencies
The different between this package and similar existing packages is it relies entirely on your `package.json` and that of your dependencies installed in `node_modules`. Other packages (e.g. [lsmod](https://www.npmjs.com/package/lsmod)) use things like `require.cache` which is dependent on runtime of your app.
## Install
```shell
yarn add ls-installed-deps
# or npm
npm install ls-installed-deps
```
## Use
```javascript
const lsDeps = require('ls-installed-deps')
lsDeps(opts)
//> { lodash: '4.17.11' }
```
### Options
#### cwd
`String`
Default: `process.cwd()`
#### devDeps
`Boolean`
Default: `false`
Include devDependencies in the result
#### shallow
`Boolean`
Default: `false`
Instead of recursively finding all deps and sub-deps, only find top-level deps of the cwd
## License
[MIT](LICENSE)