Fork me on GitHub
Pepijn de Vos16:08:46

How do I make Calva understand some def* macro declares a symbol instead of making my whole file red?


@pepijndevos We should document this, but basically you configure clj-kondo to treat those macros the same as def or whatever is the closest match.


@pepijndevos In .clj-kondo/config.edn: {:lint-as {your.ns/your-def clojure.core/def}}


or clojure.core/defn (depending on what it does)

Pepijn de Vos16:08:45

awesome thanks

Pepijn de Vos16:08:09

Amazing, it works

Pepijn de Vos17:08:07

Hm well that joy was short lived, as the Rum macro has some weird extras before the argument list that throws of the rest. Is def-catch-all what I want here?


Feel free to ask in #clj-kondo for more info on clj-kondo config


Those hooks actually expand the rum macros in such a way that clj-kondo fully understands them