8000 Clip lifecycle metadata integration for clj-kondo · Issue #35 · juxt/clip · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Clip lifecycle metadata integration for clj-kondo #35

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jvia opened this issue Mar 23, 2023 · 4 comments
Open

Clip lifecycle metadata integration for clj-kondo #35

jvia opened this issue Mar 23, 2023 · 4 comments

Comments

@jvia
Copy link
jvia commented Mar 23, 2023

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.

(defn ^:juxt.clip/lifecycle start-component [config] 
  ,,,,)
@SevereOverfl0w
Copy link
Collaborator

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"?

@jvia
Copy link
Author
jvia commented Apr 3, 2023

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.

@SevereOverfl0w
Copy link
Collaborator

Makes sense. I don't know how you would configure clojure-lsp to know a function is "publically exported" internally.

@SevereOverfl0w
Copy link
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0