Cmd-deps

Get cmd or amd dependences


Project maintained by nuintun Hosted on GitHub Pages — Theme by mattgraham

cmd-deps

Get cmd dependences

NPM Version Download Status Linux Status Windows Status Test Coverage Dependencies

Installation

npm install cmd-deps

Api

Example

js:

require('a');
//require('b');
/require('c')/;
'require("d")';
if(true)/require('e')/;
do /require('f')/.test(s); while(false);
require.async('g');
require.async(['h']);

parser output:

[
  {  
    "flag": null,
    "path": "a"
  },
  {  
    "flag": 'async',
    "path": "g"
  },
  {  
    "flag": 'async',
    "path": "h"
  }
]

License

MIT