Clojurians
#luminus
<
2016-07-10
>

This page is not created by, affiliated with, or supported by Slack Technologies, Inc.

mkaschenko06:07:52

Is there better way to convert database_column_names_to clojure-keywords in query results than overriding HugSQL result types or passing {:identifiers #(.replace % \_ \-)} explicitly everywhere? http://clojure-doc.org/articles/ecosystem/java_jdbc/using_sql.html#clojure-identifiers-and-sql-entities https://github.com/layerware/hugsql/issues/21

mkaschenko06:07:26

Also could someone explain what's the difference between using vars instead of raw functions when defining routes?

(def app-routes
  (routes
    (-> #'home-routes ;; or home-routes
        (wrap-routes middleware/wrap-csrf)
        (wrap-routes middleware/wrap-formats))))

(defn app [] (middleware/wrap-base #'app-routes)) ;; or app-routes