summaryrefslogtreecommitdiff
path: root/Biz/Devalloc/Node.hs
diff options
context:
space:
mode:
authorBen Sima <ben@bsima.me>2020-12-06 12:05:58 -0500
committerBen Sima <ben@bsima.me>2020-12-06 12:22:33 -0500
commitdee8c3aafb41d984bc69274ed320272ee7ee2bbf (patch)
tree53c943629cc7e5d1d574cecde081f20749eb90af /Biz/Devalloc/Node.hs
parent83c473947589cd90fc74fb59e9c9c28a677583c3 (diff)
Remove Miso from Devalloc
I decided to finish the Devalloc frontend by just removing it. This way I can have everything in one file, the code is much simpler, and I can scale up as needed. Anyway, this works fine with Turbolinks and that's pretty cool, so you get the same basic feel as with any other SPA.
Diffstat (limited to 'Biz/Devalloc/Node.hs')
-rw-r--r--Biz/Devalloc/Node.hs32
1 files changed, 0 insertions, 32 deletions
diff --git a/Biz/Devalloc/Node.hs b/Biz/Devalloc/Node.hs
deleted file mode 100644
index 51acbf1..0000000
--- a/Biz/Devalloc/Node.hs
+++ /dev/null
@@ -1,32 +0,0 @@
-{-# LANGUAGE NoImplicitPrelude #-}
-{-# LANGUAGE RecordWildCards #-}
-
--- : out devalloc.js
---
--- : dep clay
--- : dep ghcjs-base
--- : dep miso
--- : dep potolude
--- : dep servant
--- : dep text
-module Biz.Devalloc.Node (main) where
-
-import Alpha
-import qualified Biz.Devalloc.Core as Core
-import Miso
-
-main :: IO ()
-main = miso <| \currentURI -> App {model = Core.make currentURI, ..}
- where
- update = move
- view = view
- subs = []
- events = defaultEvents
- initialAction = Core.NoOp
- mountPoint = Nothing
-
-move :: Core.Move -> Core.Form -> Effect Core.Move Core.Form
-move mov form = case mov of
- Core.NoOp -> noEff form
- Core.ChangeURI u -> form <# (pushURI u >> pure Core.NoOp)
-