Elm library to pair with my Go backend

Hi, this is my first time asking here. I have a backend made with Go, now I want to pair it with Elm but I don’t know what will be the best fit library to use. I saw elm-spa and elm-pages, but I’m confuse what to pick, btw my frontend also needs authentication, and routing guard. TIA.

Hi @mystique09. Basically all elm application use what is called TEA (The Elm Architecture). Using elm in the frontend is very much the same whatever backend you use. You simply need to be able to serve an html and a JS file (where the JS is the result from elm compilation). Some more info about that in the guide.

Regarding how your app is organized, many like the way Richard’s “Real World” example app is structured.
Now there also exists a few helper frameworks such as Elm Land (successor to elm-spa).
And a few static site generator libraries such as elm-pages.

If not already, I’d suggest registering to the elm slack, where you can more easily find out what really fits your needs.

1 Like

I use elm-spa and like it a lot. Here is repo:

api and frontend directories may be of interest. We build and compress the elm.js file (only 50KB) and then embed that using go-embed. We then serve the compressed file by using this HTTP wrapper that decompresses the file on the fly:


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