Fork me on GitHub

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.


How can I disable it?


The command is npx shadow-cljs -d cider/cider-nrepl:0.27.4 watch :app


@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.


The command works fine except the warning.


> 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.


yes, in a place where shadow-cljs will not find it.


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


that way you won't get the warning


of course your build outputs will still fail to run without the missing dependencies


Noob question. Has anyone used sync-fetch from npm in a node.js app?