Fork me on GitHub
#clj-kondo
<
2020-05-26
>
tatut04:05:47

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

borkdude06:05:48

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

tatut06:05:58

👍 I’ll try that

plins20:05:58

is there a preferred way of parsing cli arguments? lets say run $ ./my-bb-script.clj --foo bar --x y , is there and a symbol like *`command-line-args*` that would hold a map of args in babashka?

plins20:05:58

is there a preferred way of parsing cli arguments? lets say run $ ./my-bb-script.clj --foo bar --x y , is there and a symbol like *`command-line-args*` that would hold a map of args in babashka?

tanzoniteblack20:05:45

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

borkdude20:05:19

babashka quetions can be posted in #babashka