You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have read the Clojure etiquette and will respect it when communicating on this platform.
Is your feature request related to a problem? Please describe.
In our company, we want to create a wrapper around js/fetch that will add standard instrumentation to the request headers. So, we'd like to discourage the use of js/fetch directly but rather show a linting error, saying "instead of js/fetch use web.http/js-fetch". However, clj-kondo does not currently support linting JavaScript vars and so linters such as discouraged-var and custom hooks cannot solve this problem. For example,
Is your feature request related to a problem? Please describe.
In our company, we want to create a wrapper around
js/fetch
that will add standard instrumentation to the request headers. So, we'd like to discourage the use ofjs/fetch
directly but rather show a linting error, saying "instead of js/fetch use web.http/js-fetch". However,clj-kondo
does not currently support linting JavaScript vars and so linters such asdiscouraged-var
and custom hooks cannot solve this problem. For example,web.http/js-fetch'
shows a linting error as expected, however,js/fetch
does not.Describe the solution you'd like
A clear and concise description of what you want to happen.
I would like to be able to show a linting error when
js/fetch
is used by using code like this,Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
discouraged-var
linterThe text was updated successfully, but these errors were encountered: