js-module-dependencies

0.0.2 • Public • Published

js-module-dependencies

Find dependencies between JavaScript modules in a project.

Work-in-progress, currently supports import, export ... from.

Installation

npm install js-module-dependencies

Usage

var jsModuleDependecies = require('./index.js');

jsModuleDependecies.getModuleDependenciesInProject(
  '/Users/lev/tmp/react-dnd/src',
  console.log
);

Output:

{ DragDropContext:
   [ 'react',
     'dnd-core',
     'invariant',
     'utils/checkDecoratorArguments',
     'hoist-non-react-statics' ],
  DragLayer:
   [ 'react',
     'utils/shallowEqual',
     'utils/shallowEqualScalar',
     'lodash/isPlainObject',
     'invariant',
     'utils/checkDecoratorArguments',
     'hoist-non-react-statics' ],
...

Package Sidebar

Install

npm i js-module-dependencies

Weekly Downloads

1

Version

0.0.2

License

ISC

Last publish

Collaborators

  • bagilevi