elm-spa/README.md
Ryan Haskell-Glatz 377f81c79f rename folders
2019-10-16 00:02:06 -05:00

1.1 KiB

ryannhg/elm-app

an experiment for creating single page apps with Elm!

try it out

  1. npm install

  2. npm run dev

overview

module Main exposing (main)

import Application exposing (Application)
import Generated.Pages as Pages
import Generated.Route as Route
import Layout as Layout


main : Application () Pages.Model Pages.Msg
main =
    Application.create
        { routing =
            { fromUrl = Route.fromUrl
            , toPath = Route.toPath
            }
        , layout =
            { view = Layout.view
            }
        , pages =
            { init = Pages.init
            , update = Pages.update
            , bundle = Pages.bundle
            }
        }

supporting code