scalajs-bundler icon indicating copy to clipboard operation
scalajs-bundler copied to clipboard

Minor error in example common.webpack.config.js

Open abrighton opened this issue 5 years ago • 0 comments

The example common.webpack.config.js file from https://scalacenter.github.io/scalajs-bundler/cookbook.html#global-namespace contains a minor error that can cause problems when an npm module name contains a hyphen:

Please replace test: require.resolve(modName) with test: require.resolve(globalModules[modName]).

That way you can use a name on the left side that does not contain a hyphen, which results in invalid code.

abrighton avatar Mar 07 '19 10:03 abrighton