cljs

Re-Frame + Reagent CLJS Router Pattern

TIL how to implement a routing component using Re-frame and Reagent in CLJS. This has been one of the joys for me in using CLJS, things that seem like they would be complicated on the surface, end up being just a few lines of code. With this routing component, the key is to have the current page key as a symbol in the Re-frame state (sweet sweet re-frame.db/app-db), then to subscribe to that state in our component that does the routing.