This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-04-12
Channels
- # beginners (47)
- # boot (5)
- # bristol-clojurians (1)
- # cider (45)
- # clara (2)
- # cljs-dev (11)
- # cljsrn (47)
- # clojure (169)
- # clojure-brasil (2)
- # clojure-dusseldorf (22)
- # clojure-finland (1)
- # clojure-italy (9)
- # clojure-nl (3)
- # clojure-poland (2)
- # clojure-russia (4)
- # clojure-spec (79)
- # clojure-uk (105)
- # clojurescript (59)
- # core-async (41)
- # cursive (31)
- # datomic (10)
- # devcards (1)
- # duct (6)
- # editors (9)
- # emacs (12)
- # figwheel (1)
- # fulcro (50)
- # java (4)
- # mount (1)
- # off-topic (47)
- # onyx (33)
- # pedestal (1)
- # protorepl (1)
- # re-frame (32)
- # reagent (45)
- # ring-swagger (6)
- # shadow-cljs (100)
- # tools-deps (6)
- # uncomplicate (27)
- # vim (3)
How would I disable middleware (in metosin/compojure-api), for nested routes. For example, how do we remove parent-middleware application for the “child” context. In this case, I just want the child-middleware.
(context "parent" []
:middleware [parent-middleware]
...
(context "child" []
:middleware [child-middleware]
...))
So taking this a bit further, I was going through the source of composure.api.integration-test, and it seems that having nested :middleware definitions, is additive. http://metosin.github.io/compojure-api/doc/index.html
Does anyone know if there’s any way in compojure-api api documentation (declaratively or programmatically), that let’s you reset middlewares?
@twashing currently, there is no easy way, as it's based on Compojure and routing trees are programs and mw are applied in place.