Reputation: 2193
I’m trying to migrate webpack 1 to 2, but have trouble with jsx:
ERROR in ./src/routes/index.js
Module not found: Error: Can't resolve 'SettingsPage' in '/Users/pavel/rails/spa_frontend/src/routes'
@ ./src/routes/index.js 37:20-43
@ ./src/index.jsx
@ multi webpack-hot-middleware/client ./src/index.jsx
My config for webpack2:
https://gist.github.com/pustovalov/0292a6094bea6cdec6f84c9fab5e4d2e
Upvotes: 2
Views: 1288
Reputation: 2193
This helped me:
resolve: {
extensions: ['.js', '.jsx', '.css', '.scss']
},
Working webpack2 config:
https://gist.github.com/pustovalov/d82c2421acbb35fb4bf46a61c519ffe0
Upvotes: 5