Skip to content

Instantly share code, notes, and snippets.

@minikomi
Created April 21, 2017 09:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save minikomi/ecce9d0604359b514bd681b3f6d0772e to your computer and use it in GitHub Desktop.
Save minikomi/ecce9d0604359b514bd681b3f6d0772e to your computer and use it in GitHub Desktop.
(defn strongwrap [s] (str "<strong>" s "</strong>"))
(defn strongify-keywords [s]
(s/replace s #":[a-z0-9-]+" strongwrap))
(defn pprinter [v]
[:pre
[:code {:dangerouslySetInnerHTML
{:__html (->> (with-out-str (pp/pprint v))
strongify-keywords)}}]])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment