You're looking for an update-attr
function, was discussed before
As in:
(html/deftemplate template-about "../resources/public/build/about/index.html"
[]
[:img] (fn [node]
(let [href (-> node :attrs :href)]
(assoc-in node [:attrs :href] (urly/path-of href))))
Or taking the generic path
(defn update-attr [attr f & args]
(fn [node]
(apply update-in node [:attrs attr] f args))))
and then
(update-attr :href urly/path-of)