The webpack.config.js line for exposing the Bluebird promise library in my (Aurelia) webapp is as follows:
module.exports = {
module: {
rules: [
{
test: /[\/\\]node_modules[\/\\]bluebird[\/\\].+\.js$/,
loader: 'expose-loader?Promise'
},
],
},
};
I have since updated the expose-loader to v1.0. Now, after bundling, I get this error in the browser console:
Error: Module build failed (from ./node_modules/expose-loader/dist/cjs.js): ValidationError: Invalid options object. Expose Loader has been initialized using an options object that does not match the API schema.
- options misses the property 'exposes'. Should be: non-empty string | object { globalName, moduleLocalName?, override? } | [non-empty string | object { globalName, moduleLocalName?, override? }, ...] (should not have fewer than 1 item)
How should the config be changed to reflect the new API?
Many thanks!