Fork me on GitHub

this might sound noobish, but is there a way to build web paths in a "portable" way ? Right now I use str but I noticed it failed when I added (ring/redirect-trailing-slash-handler) . This is because I had "/clicked" and after rediect-handler I had "//clicked" .

(defn home [request]
  (let [{:keys [uri]} request
        clicked-path (str uri "clicked")]
      [:h1 "Welcome to Htmx + Kit module"]
      [:button {:hx-post clicked-path :hx-swap "outerHTML"} "Click me!"]])))
Is there an utility that can build paths from parts like for filesystem e.g. ?


it feels like it's overkill but there's


thanks, the library looks nice . I will check it out