mirror of
https://github.com/edufeed-org/edufeed-web.git
synced 2025-12-10 00:34:34 +00:00
some stuff kind of works now
This commit is contained in:
commit
36dad21f43
10 changed files with 545 additions and 0 deletions
24
src/ied/core.cljs
Normal file
24
src/ied/core.cljs
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
(ns ied.core
|
||||
(:require
|
||||
[reagent.dom :as rdom]
|
||||
[re-frame.core :as re-frame]
|
||||
[ied.events :as events]
|
||||
[ied.routes :as routes]
|
||||
[ied.views :as views]
|
||||
[ied.config :as config]))
|
||||
|
||||
(defn dev-setup []
|
||||
(when config/debug?
|
||||
(println "dev mode")))
|
||||
|
||||
(defn ^:dev/after-load mount-root []
|
||||
(re-frame/clear-subscription-cache!)
|
||||
(let [root-el (.getElementById js/document "app")]
|
||||
(rdom/unmount-component-at-node root-el)
|
||||
(rdom/render [views/main-panel] root-el)))
|
||||
|
||||
(defn init []
|
||||
(routes/start!)
|
||||
(re-frame/dispatch-sync [::events/initialize-db])
|
||||
(dev-setup)
|
||||
(mount-root))
|
||||
Loading…
Add table
Add a link
Reference in a new issue