Fork me on GitHub
#lsp
<
2021-03-29
>
borkdude15:03:55

@ericdallo idea: clj-kondo has a :consistent-alias linter, but you have to configure the aliases yourself in how you want to link full namespace names to aliases. since clojure-lsp scans your entire project, it could figure out what aliases are already used the most for which namespace and then populate this map inside .clj-kondo/config.edn once.

ericdallo15:03:14

looks a good idea!

ericdallo15:03:11

If i have a namespace on this linter for example, str for clojure.string and I write a string/join and require it, it will complain about it, is that right?

ericdallo15:03:53

nice, we probably would do that every first time we scan the project?

ericdallo15:03:20

I mean, when we do a classpath scan, (new deps or deps changed)

borkdude15:03:21

yeah and only if the alias isn't already in there

👍 3
borkdude15:03:29

and probably also only when you enable it

ericdallo15:03:42

yes, it'd need to be in a disabled feature flag for now