This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-04-11
Channels
- # announcements (3)
- # asami (4)
- # babashka (79)
- # babashka-sci-dev (47)
- # beginners (97)
- # biff (12)
- # calva (7)
- # clj-commons (3)
- # clj-kondo (22)
- # clj-on-windows (13)
- # cljdoc (31)
- # cljfx (2)
- # cljs-dev (1)
- # clojure (85)
- # clojure-austin (4)
- # clojure-dev (12)
- # clojure-europe (15)
- # clojure-italy (8)
- # clojure-nl (4)
- # clojure-uk (4)
- # community-development (19)
- # conjure (3)
- # core-typed (40)
- # cursive (9)
- # datahike (21)
- # datomic (1)
- # emacs (7)
- # exercism (2)
- # graalvm (20)
- # graphql (1)
- # honeysql (16)
- # jobs (1)
- # malli (2)
- # off-topic (3)
- # pathom (28)
- # pedestal (3)
- # polylith (7)
- # reitit (14)
- # releases (1)
- # remote-jobs (1)
- # rewrite-clj (4)
- # shadow-cljs (21)
- # sql (21)
- # testing (8)
- # tools-deps (23)
- # vscode (8)
- # xtdb (38)
I am running with the aot version, specifically
{thheller/shadow-cljs$aot {:mvn/version "2.18.0"}}
There is a warning: WARNING: shadow-cljs not installed in project.@i that warning is about the npm shadow-cljs package not being installed in the project. which you should definitely do when using npx
. so just npm install shadow-cljs
. not related to the aot version in any way.
> which you should definitely do when using npx
Why is it a necessity? The reason I use npx is that I do not need to install shadow.
that makes no sense. if you use a tool you should install it. it also brings with it depenendencies that may be necessary. eg. for node-repl
source maps and other stuff
I did a fresh install on a debian system, and just run npx shadow-cljs
. The prompted as in the first picture. I then checked the directory _npx, i found the source-map and other dependencies are all installed.
Not sure on the ‘will not found it’ part. Perform the following actions resulting the same directory layout.
mkdir -p test && cd test
npm install -D shadow-cljs
yes, not how that node_modules/shadow-cljs
dir is part of your project test
dir. and the above in somewhere outside the project dir
Not sure what you are referring to. For the npx approach, it installs all the dependency. The only difference is, for the npx one, the shadow-cljs package is put in some-where/npx/modules, while the other approach installs shadow in $PROJ/nodemodules.
Indeed the _npx/modules are outside the project path, but if it poses a problem, then its some erroneous logic of the library itself.
For me, running npx shadow-cljs
is all fine, except the shadow-cljs not installed in the project warning
.
ok simple test. create a :node-script
build to output to the out
directory in the project directory. run node out/whatever.js
it'll fail because it also cannot find files in .npx
, just as shadow-cljs does not look in ~/.npx
when compiling
yes running via npx
works. but this is not at all what this warning is about. it is about compilation and running outputs. NOT about running shadow-cljs
itself
if you don't like it or want to ignore me just bypass running shadow-cljs
completely
clj -A:dev -M -m shadow.cljs.devtools.cli watch app
is similar to npx shadow-cljs watch app
. only server mode is not supported. as described https://code.thheller.com/blog/shadow-cljs/2017/11/18/the-many-ways-to-use-shadow-cljs.html