Open alex-tan opened 3 years ago
does that file have anything named main
- even an in-line let
statement
No, nothing called main in that file. I ended up resolving the issue by moving the file to a nested directory, though didn't figure out what was causing the issue.
In my case, this line
import { getDimensions } from "../../../shared/Runtime/runtime.js";
was leading webpack to attempt to compile ../../../shared/Runtime/Runtime.elm
and this file does not have main
in it
This elm file was imported by by Elm entry point but not sure whether that matters - comment the above line out, or renaming to RuntimeSOMETHING.elm seems to be a workaround
I'm running into an issue where I have a single entry for my webpack config
entry: "./src/index.ts"
. That file imports a single Elm appimport { Elm } from "./App.elm";
but for some reason when I upgraded to"elm-webpack-loader": "^8.0.0"
from the elm-webpack-starter I've started seeing it attempt to compile an additional file in my src/ directory calledsrc/Events.elm
. This causes the elm compiler to complain withWhich is strange because there are other elm files in the root of the src directory that it doesn't seem to care about.
I attempted to debug the issue by specifying the
files
option to be['src/App.elm']
which resolves the issue but causes each save to trigger 3 compilations in the terminal.If anyone has any hunches about why this might be happening it would be much appreciated.