slue-vars

save variables in the namespace slue

Usage no npm install needed!

<script type="module">
  import slueVars from 'https://cdn.skypack.dev/slue-vars';
</script>

README

slue-vars

Save vars at slue.vars

example

const slue = require('slue');
const slueStream = require('slue-stream');
const slueVars = require('../index.js');

slue.read('./test/app.js').pipe(slueVars(function() {
    return {
        a: 'a.js',
        b: 'b.js'
    }
})).pipe(slueStream.transformObj(function(file, env, cb) {
    console.log(slue.vars);
}));