Skip to content

Commit

Permalink
refactor: use "Tonsky Formatting"
Browse files Browse the repository at this point in the history
This allow to have consistent formatting between VS Code and IDEA
@see clj-commons/formatter#9 (comment)
  • Loading branch information
maksimr committed Mar 24, 2022
1 parent d2bd256 commit 6b04807
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 9 deletions.
10 changes: 10 additions & 0 deletions .cljfmt.edn
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{:remove-surrounding-whitespace? true
:remove-trailing-whitespace? true
:remove-consecutive-blank-lines? false
:insert-missing-whitespace? false
:indents ^:replace {#"^\w" [[:inner 0]]}
:test-code
(concat [2]
(map #(inc (* % 2))
(filter #(aget sieved %)
(range 1 hn))))}
12 changes: 6 additions & 6 deletions shadow-cljs.edn
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{:source-paths ["src" "scripts"]
:dev-http {9000 "public"}
:builds {:client {:target :browser
:output-dir "public/js"
:asset-path "js"
:builds {:client {:target :browser
:output-dir "public/js"
:asset-path "js"
:build-hooks [(build-hooks/setup)]
:modules {:main {:entries [client.core]}}}
:server {:target :node-script
:modules {:main {:entries [client.core]}}}
:server {:target :node-script
:output-to "public/js/server.js"
:main server.core/main}}}
:main server.core/main}}}
6 changes: 3 additions & 3 deletions src/client/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

(defn -main []
(set!
(.-innerText
(js/document.getElementById "app"))
"Hello World!"))
(.-innerText
(js/document.getElementById "app"))
"Hello World!"))

(-main)

0 comments on commit 6b04807

Please sign in to comment.