pkg-dep-tree

1.2.1 • Public • Published

pkg-dep-tree

🌲 A better npm list.

npm list is a really useful tool for visualising your dependency tree. It's quite hard to use within your application and focuses on the node_modules folder however. pkg-dep-tree aims to empwoer developers to print out peer dependency structures given a package.json file with support for mono repos.


I'm aspiring to make open-source my full-time work. If you like the work that I do, please consider supporting me.

Coffee PayPal

Install

npm i pkg-dep-tree

Usage

Module

const { GetMonoDepTree, PrintTreeTrim } = require( 'pkg-dep-tree' );
 
(async () => {
    let workspace = Path.join( __dirname, '/../components' );
    let org = '@gov.au';
    let treeObject = await GetMonoDepTree( workspace, 'side-nav', org );
 
    console.log( await PrintTreeTrim( treeObject ) );
})();

Output

├─ core
├─ animate
├─ accordion
│  ├─ animate
│  └─ core
└─ link-list
   ├─ core
   └─ body
      └─ core

Test

npm test

Contribute

Don't be scared raise an issue or a pull request! Any contributions, no matter how big or small will land your picture here.

Adam Zerella

/pkg-dep-tree/

    Package Sidebar

    Install

    npm i pkg-dep-tree

    Weekly Downloads

    0

    Version

    1.2.1

    License

    MIT

    Unpacked Size

    5.28 kB

    Total Files

    4

    Last publish

    Collaborators

    • azerella