Open shiwanlin opened 8 years ago
I took a quick look at the source, and this is already possible, as such:
var options = {}; // build options as per documentation
var obfuscator = require('obfuscator').obfuscator;
var concatenate = obfuscator.concatenate;
concatenate(options, function(err, concatenated) {
if (err) { throw err; }
fs.writeFileSync('concatenated.js', concatenated);
// or, you know, do whatever you like
});
That's cool - thanks!
Not a high priority but a nicety to have an option to output the concatenated source so uglifyjs warning can be taken care of more easily, say, in utils.js,
with the source output, the line number from the uglifyjs warning can be easily found:
BTW, obfuscator is a great tool!