Webpack 4.0.0 Error
See original GitHub issueI am trying to use Webpack v4.0.0 and get the following:
ERROR in ./src/Main.elm
Module build failed: TypeError: Cannot read property 'elm' of undefined
at Object.getOptions (/Users/me/dev/Projects/Elm/webpack4/node_modules/elm-webpack-loader/index.js:37:35)
at Object.module.exports (/Users/me/dev/Projects/Elm/webpack4/node_modules/elm-webpack-loader/index.js:117:28)
@ ./src/index.js 1:10-31
webpack.config.js
module.exports = {
module: {
rules: [
{
test: /\.elm$/,
exclude: [/elm-stuff/, /node_modules/],
use: {
loader: 'elm-webpack-loader'
}
}
],
noParse: [/\.elm$/]
}
};
src/index.js
const Elm = require('./Main.elm');
// import Elm from './Main.elm'
console.log('App started...');
src/Main.elm
module Main exposing (main)
import Html exposing (Html, text)
main : Html msg
main =
text "Hello, Elm!"
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:11 (2 by maintainers)
Top Results From Across the Web
webpack 4.0.0-alpha.0 feedback · Issue #6064 - GitHub
And here's an error from running webpack from rails/webpacker: ... Trying to build 3.10 project with webpack 4.0.0-alpha.0 - it fails after ...
Read more >Unresolved dependency peer webpack@"^4.0.0" from css ...
Based on the error message, there is dependency conflict between css-loader@^2.1.1" and webpack@^4.0.0 . Try npm uninstall --save-dev ...
Read more >webpack-cli - npm
webpack CLI provides a flexible set of commands for developers to increase speed when setting up a custom webpack project. As of webpack...
Read more >Installation | webpack
This guide goes through the various methods used to install webpack. Prerequisites. Before we begin, make sure you have a fresh version of...
Read more >Solved: Module not found: Error: Can't resolve 'sass-loader'
While resolving: twotter@0.1.0 npm ERR! Found: webpack@4.46.0 npm ERR! node_modules/webpack npm ERR! peer webpack@"^4.0.0" from @intervolga/ ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
published as 4.5.0
#136