aboutsummaryrefslogtreecommitdiff
path: root/client/src/Component/Form.hs
diff options
context:
space:
mode:
authorJoris2018-01-28 12:13:09 +0100
committerJoris2018-06-11 12:28:29 +0200
commit33b85b7f12798f5762d940ed5c30f775cdd7b751 (patch)
treedaf8cfb7b0a16b2fce65848fc0ca2831f33a0701 /client/src/Component/Form.hs
parentab17b6339d16970c3845ec4f153bfeed89eae728 (diff)
downloadbudget-33b85b7f12798f5762d940ed5c30f775cdd7b751.tar.gz
budget-33b85b7f12798f5762d940ed5c30f775cdd7b751.tar.bz2
budget-33b85b7f12798f5762d940ed5c30f775cdd7b751.zip
WIP
Diffstat (limited to 'client/src/Component/Form.hs')
-rw-r--r--client/src/Component/Form.hs12
1 files changed, 12 insertions, 0 deletions
diff --git a/client/src/Component/Form.hs b/client/src/Component/Form.hs
new file mode 100644
index 0000000..0a89c6e
--- /dev/null
+++ b/client/src/Component/Form.hs
@@ -0,0 +1,12 @@
+module Component.Form
+ ( form
+ ) where
+
+import qualified Data.Map as M
+import Reflex.Dom (MonadWidget)
+import qualified Reflex.Dom as R
+
+form :: forall t m a. (MonadWidget t m) => m a -> m a
+form content =
+ R.elAttr "form" (M.singleton "onsubmit" "event.preventDefault()") $
+ content