This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <title>SAFE Template</title> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.9.0/css/bulma.min.css"/> | |
| <script src="https://kit.fontawesome.com/409fb4cc7a.js" crossorigin="anonymous"></script> | |
| </head> | |
| <body> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module View | |
| open Feliz | |
| open Feliz.Bulma | |
| open System | |
| open Model | |
| open Messages | |
| let view (state : Model) dispatch = |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module Update | |
| open System | |
| open Elmish | |
| open Fable.SimpleHttp | |
| open Model | |
| open Messages | |
| let tryParseWith (tryParseFunc: string -> bool * _) = tryParseFunc >> function |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module Model | |
| [<RequireQualifiedAccess>] | |
| type EventSet = | |
| | Small | |
| | Large | |
| type Model = | |
| { EventSet: EventSet | |
| PlaybackDelay : int |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module View | |
| open Feliz | |
| open System | |
| open Model | |
| open Messages | |
| let view (state : Model) dispatch = |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module App | |
| open Elmish | |
| open Elmish.React | |
| open Update | |
| open View | |
| Program.mkProgram init update view | |
| |> Program.withReactSynchronous "elmish-app" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module App | |
| open Elmish | |
| open Elmish.React | |
| #if DEBUG | |
| open Elmish.Debug | |
| open Elmish.HMR | |
| #endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module Index | |
| open Elmish | |
| open Fable.SimpleHttp | |
| type Model = { | |
| Filename: string | |
| Events : string | |
| Error : string } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module App | |
| open Elmish | |
| open Elmish.React | |
| Program.mkProgram Index.init Index.update Index.view | |
| |> Program.withReactSynchronous "elmish-app" | |
| |> Program.run |