Add the urls of main pages for navbar.

main
KKlochko 1 year ago
parent 2f82f419d7
commit 9d2f940a07

@ -13,7 +13,8 @@
(let [articles (<! (db/get-articles-briefly client channel))] (let [articles (<! (db/get-articles-briefly client channel))]
(res/status 200) (res/status 200)
(.render res "index" (.render res "index"
(-> {:articles articles} (-> {:articles articles
:url "/"}
(cljs.core/clj->js)))) (cljs.core/clj->js))))
(catch js/Error err (catch js/Error err
(res/status 500) (res/status 500)
@ -29,7 +30,8 @@
(let [articles (<! (db/get-articles-briefly client channel))] (let [articles (<! (db/get-articles-briefly client channel))]
(res/status 200) (res/status 200)
(.render res "admin_panel" (.render res "admin_panel"
(-> {:articles articles} (-> {:articles articles
:url "/admin"}
(cljs.core/clj->js)))) (cljs.core/clj->js))))
(catch js/Error err (catch js/Error err
(res/status 500) (res/status 500)

Loading…
Cancel
Save