Closed NoahTheDuke closed 10 months ago
Hey friends!
I'm looking to use CHIPS in :cookies, but because the set-cookie-attrs is a private var, I can't add support for it myself:
:cookies
set-cookie-attrs
https://github.com/ring-clojure/ring/blob/76e5d29128661225a08a9f8dfa7b07c83b6ed4da/ring-core/src/ring/middleware/cookies.clj#L21-L24
At the moment I'm using alter-var-root and alter-meta to gain access and insert it (see below), but that feels less good than maybe making it an atom and allowing it to be edited by users, or some other system that I trust y'all to come up with.
alter-var-root
alter-meta
(alter-meta! #'ring.middleware.cookies/set-cookie-attrs assoc :private false) (alter-var-root #'ring.middleware.cookies/set-cookie-attrs assoc :partitioned "Partitioned")
This is a good idea. I'd happy access a pull request for this, but if you don't have time I'll try to add this next week.
Hey friends!
I'm looking to use CHIPS in
:cookies
, but because theset-cookie-attrs
is a private var, I can't add support for it myself:https://github.com/ring-clojure/ring/blob/76e5d29128661225a08a9f8dfa7b07c83b6ed4da/ring-core/src/ring/middleware/cookies.clj#L21-L24
At the moment I'm using
alter-var-root
andalter-meta
to gain access and insert it (see below), but that feels less good than maybe making it an atom and allowing it to be edited by users, or some other system that I trust y'all to come up with.