webpack/test/fixtures/errors/irregular-error-loader.js

11 lines
244 B
JavaScript

module.exports = function(source) {
const empty = null;
const emptyError = new Error();
this.emitWarning(empty);
this.emitWarning(emptyError);
this.emitError(empty);
this.emitError(emptyError);
throw "a string error";
return source;
};