2.0.11 • Published 2 years ago
slue-module v2.0.11
slue-module
A tool of analyse modules relationship.
API
const slueModule = require('slue-module');
let realyData = slueModule(options);
options:
{
// the file to analyse
filePath: './test/app.js',
root: '/',
prevHandler() {}
// external global variables
externals: {
'react': 'React'
},
// when exclude return true, the required module will be ignore
exclude: function(opts) {
return opts.moduleId == 'xxx';
},
// the ext names of the files which to analyse
ext: ['.js', '.jsx', '.css', '.less', '.html'],
// alias make module require shorter
alias: {
components: path.join(__dirname, './components')
}
};
output:
{
// file path and it's require id
moduleList: [
{
id: 'xxx', // require id
dir: 'xxx' // file path
}
],
// all handled files, used file path to be key
handledFile: {}
};
2.0.9
2 years ago
2.0.11
2 years ago
2.0.10
2 years ago
2.0.7
2 years ago
2.0.6
2 years ago
2.0.8
2 years ago
2.0.5
3 years ago
2.0.4
3 years ago
1.2.18
3 years ago
2.0.3
3 years ago
2.0.2
3 years ago
2.0.1
3 years ago
2.0.0
3 years ago
1.2.12
3 years ago
1.2.13
3 years ago
1.2.16
3 years ago
1.2.15
3 years ago
1.2.11
4 years ago
1.2.10
4 years ago
1.2.9
4 years ago
1.2.8
4 years ago
1.2.7
5 years ago
1.2.6
5 years ago
1.2.5
5 years ago
1.2.4
6 years ago
1.2.3
6 years ago
1.2.2
6 years ago
1.2.1
6 years ago
1.2.0
6 years ago
1.1.9
6 years ago
1.1.8
6 years ago
1.1.7
6 years ago
1.1.6
6 years ago
1.1.5
6 years ago
1.1.4
6 years ago
1.1.3
6 years ago
1.1.2
6 years ago
1.1.1
6 years ago
1.1.0
6 years ago
1.0.9
6 years ago
1.0.8
7 years ago
1.0.7
7 years ago
1.0.6
7 years ago
1.0.5
7 years ago
1.0.4
7 years ago
1.0.3
7 years ago
1.0.2
7 years ago
1.0.1
7 years ago
1.0.0
7 years ago