This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-01-09
Channels
- # announcements (28)
- # babashka (8)
- # bangalore-clj (1)
- # beginners (123)
- # boot (1)
- # bristol-clojurians (1)
- # calva (3)
- # cider (30)
- # clj-kondo (42)
- # cljs-dev (5)
- # clojure (260)
- # clojure-dev (11)
- # clojure-europe (7)
- # clojure-india (1)
- # clojure-italy (2)
- # clojure-losangeles (5)
- # clojure-nl (5)
- # clojure-portugal (15)
- # clojure-uk (51)
- # clojurescript (69)
- # cursive (6)
- # data-science (21)
- # datascript (17)
- # datomic (1)
- # emacs (29)
- # figwheel-main (11)
- # fulcro (89)
- # graphql (5)
- # hoplon (2)
- # hugsql (6)
- # jobs (11)
- # juxt (1)
- # leiningen (7)
- # luminus (1)
- # malli (3)
- # off-topic (64)
- # pathom (32)
- # project-updates (1)
- # re-frame (9)
- # reagent (10)
- # reitit (21)
- # ring (5)
- # ring-swagger (1)
- # shadow-cljs (8)
- # spacemacs (6)
- # xtdb (4)
If I wanted to separate events over a number of namespaces how do I force them to load in the main events namespace ? e.g main is events.cljs, per namespace document/events.cljs and bibliography/events.cljs
I still get "re-frame: no :event handler registered for: :edit-bibliography" even though I have required them in the main events.cljs
The most likely explanation is that you haven't actually registered them (even though you are sure you have) . OR that you are registering them after their first use.
Put a println
into your code where the registration is happening, and make sure you are seeing the registration.
(println "I'm registering :edit-bibliography")
(reg-event-db :edit-bibliography
....)
Cheers - adding the println actually surfaced the issue - I hadn't :require'd re-frame/core into the new namespace ...
clj-kondo still reports the split out namespaces as unused .. do I just have to live with that ?
Will have to defer to someone with clj-kondo experience