You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem along with a gist/jsbin of your webpack configuration.
ERROR in ./index.html
Module build failed: /Users/wilsonpage/Documents/s/project/src/index.js:4
import Converter from './lib/converter';
^^^^^^
SyntaxError: Unexpected token import
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:542:28)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at /Users/wilsonpage/Documents/s/songwhip/songwhip-site/node_modules/extract-loader/lib/extractLoader.js:73:24
at require (/Users/wilsonpage/Documents/s/songwhip/songwhip-site/node_modules/extract-loader/lib/extractLoader.js:56:33)
at /Users/wilsonpage/Documents/s/songwhip/songwhip-site/src/index.html:1:1159
at ContextifyScript.Script.runInContext (vm.js:35:29)
at ContextifyScript.Script.runInNewContext (vm.js:41:15)
at Object.extractLoader (/Users/wilsonpage/Documents/s/songwhip/songwhip-site/node_modules/extract-loader/lib/extractLoader.js:87:12)
I think this may have had to do with the way extract-loader handled requires. They just released the v1.0.0 in which this was fixed. (At least in my experience.) Maybe give that one a try!
I'm submitting a bug report
Webpack version:
2.x
HTML-Loader version:
0.4.5
Please tell us about your environment:
OSX 10.x / Linux / Windows 10
OSX
Current behavior:
Webpack is not running defined loaders on modules imported into .html entrypoints.
Expected/desired behavior:
I expect the following module to be run through my defined
babel-loader
, but it's choking on ES6 syntax.Imports within
.html
files should be treated as defined in the webpack config.The text was updated successfully, but these errors were encountered: