clj-kondo

https://github.com/clj-kondo/clj-kondo
tatut 2020-05-26T04:01:47.257800Z

clj-kondo doesn’t yet know about npm requires and :as

% echo "(ns foo (:require [some-npm-module :as x])) (aget x \"default\")" | clj-kondo --lint -
<stdin>:1:20: warning: namespace some-npm-module is required but never used
<stdin>:1:51: error: unresolved symbol x
the x name is valid in cljs and is the npm module object

borkdude 2020-05-26T06:52:48.258800Z

@tatut if you will use a string for the name it will treat it as an NPM require

tatut 2020-05-26T06:53:58.259100Z

:thumbsup: I’ll try that

tanzoniteblack 2020-05-26T20:37:45.262200Z

is this a clj-kondo specific question, or just a generic clojure question?

borkdude 2020-05-26T20:38:19.262700Z

babashka quetions can be posted in #babashka