work.suroh.tk/node_modules/detective-less
suroh 410082595a init 11ty commit 2019-12-02 13:22:45 +01:00
..
Readme.md init 11ty commit 2019-12-02 13:22:45 +01:00
index.js init 11ty commit 2019-12-02 13:22:45 +01:00
package.json init 11ty commit 2019-12-02 13:22:45 +01:00

Readme.md

detective-less npm npm

Find the dependencies of a less file

npm install --save detective-less

This is a fork of a package by mrjoelkemp given a lack of a less detective, it is the counterpart to detective, detective-amd, detective-sass, detective-scss and detective-es6.

Usage

var detective = require('detective-less');

var content = fs.readFileSync('styles.less', 'utf8');

// list of imported file names (ex: 'foo.less', 'foo', etc)
var dependencies = detective(content);

License

MIT