evancz / elm-todomvc

The TodoMVC app written in Elm, nice example for beginners.
http://evancz.github.io/elm-todomvc/
BSD 3-Clause "New" or "Revised" License
1.22k stars 329 forks source link

elm-react gives me an error #64

Closed ghost closed 6 years ago

ghost commented 6 years ago

Oops! Something went wrong when starting your Elm program.

Trying to initialize the Todo module with an unexpected flag. I tried to convert it to an Elm value, but ran into this problem:

I ran into the following problems:

Expecting null but instead got: undefined Expecting an object with a field named entries but instead got: undefined

Erudition commented 6 years ago

I have the same problem, whether in elm-react or built with elm-make.

evancz commented 6 years ago

What is elm-react?

If you are trying to use the elm-reactor command, you should instead follow the Build Instructions in the README. The code in index.html is needed to get it hooked to localStorage for now.

Erudition commented 6 years ago

You're totally right Evan, I had eventually figured that solution out for myself just recently. And yes, we meant elm-reactor, although in this case the same issue happens with elm-make until you add the flag for elm.js - in which case you need to re-download the original index.html because it was overwritten by the compiled one.

evancz commented 6 years ago

Okay, I think the instructions are not ideal, but I also do not see a clear path to making them easier. I will close for now, but I agree that the current situation is confusing!