Closed Kilian closed 6 years ago
I ran into the same issue, both with HTTP and Json
Yeah, this guide needs a revamp, it should be more like MDN where you can contribute and even translate... Next big step... Wish I knew enough to start moving it myself
I was able to fill in the missing steps by first installing the elm-lang/http package
$ elm-package install elm-lang/http
And then by adding these imports at the top of the file:
import Http
import Json.Decode as Json
This is also a duplicate of this issue: https://github.com/evancz/guide.elm-lang.org/issues/21 and addressed by this PR (opened Sept 2016 with no response).
The new version of the book includes all the examples in full!
The tutorial on https://github.com/evancz/guide.elm-lang.org/blob/master/architecture/effects/http.md is not self-contained and tripped me up for a number of reasons.
"evancz/elm-http" is not a logical name and it, alongside how to install it, should be mentioned in the tutorial.
A quick mention on top of phase two of "by the way, the http module is located here, and you need to install and import it" would be a good idea so people do not have to look elsewhere to get their local example working.