Short and sweet, I want a stack trace when this fails:
require('something');
I've tried:
var domain = require('domain').create();
domain.on('error', function(error) {
console.error('error', error);
});
domain.run(function() {
require('something');
});
I get the code MODULE_NOT_FOUND, but no trace. Is this possible? This would make development easier when working on large projects with many custom modules, when a module breaks.
Aucun commentaire:
Enregistrer un commentaire