Open jvia opened 1 year ago
They shouldn't be marked as unused by clj-kondo if they're public functions? They might be marked as unused by clojure-lsp though if it doesn't treat your namespace as a "library"?
OK, after some more poking at this, I think it is clojure-lsp that is causing the issue. If I run clj-kondo
at the command line I do not see any warnings about the unused public var.
Makes sense. I don't know how you would configure clojure-lsp to know a function is "publically exported" internally.
Clip lifecycle functions are marked as unused by clj-kondo. This can be resolve by ignoring the form but I think it could be a nicer UX and a clearer intent if clip exported a clj-kondo config such that adding a specific tag to a function disabled the unused check.
Basically something along the lines below. It would ignore that fact that it is unused but it's clear to developers from where this function is being used.