From 0245da0a5ad5d8712d5743067d53319f11e3b4ae Mon Sep 17 00:00:00 2001 From: Junyi Du Date: Thu, 18 Nov 2021 19:21:59 +0800 Subject: [PATCH] Expand kondo configuration --- .clj-kondo/config.edn | 14 ++++++++++++-- deps.edn | 6 +++++- package.json | 3 ++- 3 files changed, 19 insertions(+), 4 deletions(-) diff --git a/.clj-kondo/config.edn b/.clj-kondo/config.edn index c6e41275ad2..2bf4cbae230 100644 --- a/.clj-kondo/config.edn +++ b/.clj-kondo/config.edn @@ -1,10 +1,20 @@ -{:linters {:unresolved-symbol {:exclude [goog.DEBUG]}} +{:linters {:unresolved-symbol {:exclude [goog.DEBUG + goog.string.unescapeEntities]}} :hooks {:analyze-call {rum.core/defc hooks.rum/defc rum.core/defcs hooks.rum/defcs}} :lint-as {promesa.core/let clojure.core/let + promesa.core/loop clojure.core/loop garden.def/defstyles clojure.core/def garden.def/defkeyframes clojure.core/def rum.core/defcc rum.core/defc + rum.core/with-context clojure.core/doseq + rum.core/defcontext clojure.core/def clojure.test.check.clojure-test/defspec clojure.core/def clojure.test.check.properties/for-all clojure.core/for - frontend.modules.outliner.datascript/auto-transact! clojure.core/let}} + nubank.workspaces.core/defcard clojure.core/def + ;; src/main + frontend.modules.outliner.datascript/auto-transact! clojure.core/let + frontend.namespaces/import-vars potemkin/import-vars + ;; src/test + frontend.react/defc clojure.core/defn} + :skip-comments true} \ No newline at end of file diff --git a/deps.edn b/deps.edn index e6789833b33..9700c08472d 100755 --- a/deps.edn +++ b/deps.edn @@ -58,4 +58,8 @@ {com.cognitect/test-runner {:git/url "https://github.com/cognitect-labs/test-runner", :sha "76568540e7f40268ad2b646110f237a60295fa3c"}}, - :main-opts ["-m" "cognitect.test-runner" "-d" "src/test"]}}} + :main-opts ["-m" "cognitect.test-runner" "-d" "src/test"]} + + :clj-kondo + {:extra-deps {clj-kondo/clj-kondo {:mvn/version "2021.10.19"}} + :main-opts ["-m" "clj-kondo.main"]}}} diff --git a/package.json b/package.json index 4f5ed3c7291..de5d4221a14 100644 --- a/package.json +++ b/package.json @@ -57,7 +57,8 @@ "cljs:dev-release-app": "clojure -M:cljs release app --config-merge '{:closure-defines {frontend.config/DEV-RELEASE true}}'", "cljs:debug": "clojure -M:cljs release parser-worker app --debug", "cljs:report": "clojure -M:cljs run shadow.cljs.build-report parser-worker app report.html", - "cljs:build-electron": "clojure -A:cljs compile parser-worker app electron" + "cljs:build-electron": "clojure -A:cljs compile parser-worker app electron", + "cljs:lint": "clojure -M:clj-kondo --parallel --lint src" }, "dependencies": { "@capacitor/android": "3.2.2",