Startup error message repository

Where is the system code which generates the message, “Something went wrong when starting your Elm program.”? I haven’t found the relevant repositories.

I’d like to make a PR which would harden the styling of this message, to help beginning Elm programmers who use unusual CSS files.

For example, my use of the rule, body { font-size: 0 } caused the error message to be invisible.

So, which repositories are relevant?

I found the relevant repository.

In the compiler’s generated JavaScript output, the function containing that message is:

function checkYesFlags(flagDecoder, moduleName)

Looking in elm-stuff/exact-dependencies.json, I found the function in:

"elm-lang/virtual-dom": "2.0.4"

Elm 0.19 handles this error condition much better, by leaving its target HTML node untouched. Thus, it doesn’t generate any error message in HTML at all. (It logs an error message to the JavaScript console.)

With Elm 0.19, I can keep an appropriate error message in the program’s target node (such as, “You must reset your cache”). And this error message normally disappears, when it’s replaced by the Elm program.

In my original post, I was using Elm 0.18 which, for me, didn’t totally replace its target node, but instead allowed my error message to remain (even in normal operation).

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.