This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-09-27
Channels
- # beginners (34)
- # boot (15)
- # cider (7)
- # cljs-dev (7)
- # cljsjs (2)
- # cljsrn (46)
- # clojure (130)
- # clojure-argentina (1)
- # clojure-colombia (2)
- # clojure-greece (1)
- # clojure-italy (53)
- # clojure-losangeles (1)
- # clojure-russia (15)
- # clojure-spec (8)
- # clojure-uk (100)
- # clojurescript (117)
- # core-matrix (1)
- # cursive (24)
- # datomic (41)
- # duct (1)
- # emacs (11)
- # fulcro (22)
- # graphql (4)
- # hoplon (3)
- # jobs (1)
- # lein-figwheel (3)
- # luminus (18)
- # lumo (52)
- # off-topic (57)
- # pedestal (2)
- # planck (12)
- # re-frame (22)
- # remote-jobs (1)
- # ring-swagger (6)
- # rum (7)
- # shadow-cljs (13)
- # yada (19)
@johnnyillinois note: any update to js/window.location.href` would be a mutation, so it should be done in an effect handler
@mikethompson Do you know the API for this effect because my understanding is that reg-event-db
should only affect the db?
I know there is the reg-event-fx
but I don't know the key for window.location.href
effects
You need to read up on and understand event handlers
of the -fx
variety, which return effects
Returning a new db
is just one kind of effect
Then maybe use a library of effects like: https://github.com/SMX-LTD/re-frame-document-fx I've not tried it. But it probably shows the way
thanks mike
The docs are currently in a bit of flux as we try to use gitbook ... but you should be looking at ... https://github.com/Day8/re-frame/blob/master/docs/SUMMARY.md Look at the material under the heading "Dominoes 2 & 3"
Effectful Handlers
etc
Can anyone point to some examples or resources of client side authorization/protected routes?
@danielcompton (or anyone else in the know), if I may, https://github.com/Day8/re-frame-trace Usage "Once [your application] is loaded, focus the document window and press ctrl-h to slide open the trace panel and enable tracing."" In my Chrome browser Ctrl-H opens history. Does "document window" mean something else? (pretty new to reframe overall)
hmm, what platform are you on @bouchardsyl? we might need to make it adjustable or pick something that doesn't collide
@danielcompton thank you for your reply. I found a clever way to solve this. It was a RTFM issue...
I'm mindblown actually, re-frame-trace is oh-so-very useful. Took me an hour to figure out how to install it, then like 5 seconds to pintpoint the slow sub 🙂
@bouchardsyl what could we do to make it easier to install? Or document it?
@danielcompton I can't think of much to say, it was really me who skipped some of the "Installation" instructions and did trial and error instead. An ADD thing. Maybe add an idiot-proof statement as first bullet of the "Usage": make sure you DID follow the THREE (3) installation steps.
hahaha sure
Great tool.
@danielcompton to chime in on re-frame-trace: An incredible tool. I had trouble getting started, too. Did everything the instructions said. No traces would show up. In the end it was a lein clean that made it work. Maybe worthwhile to add to the documentation.
cool, just added that, thanks
haha nice