Fork me on GitHub
#shadow-cljs
<
2023-06-05
>
andrewzhurov19:06:41

Hi! JS lib from package.json can't get found by shadow-cljs, it gives:

[:app] Build failure:
The required JS dependency "ipfs" is not available, it was required by "dweb/db.cljs".

Dependency Trace:
	frontend/core.cljs
	frontend/dataweb_sandbox.cljs
	dweb/db.cljs

Searched for npm packages in:
	/home/user1/projects/re-frame/node_modules

See: 
Any tips on what may be the issue and how to fix? I've done npm i, the ipfs module I'm trying to refer is in node-modules, and I'm trying to require it as ["ipfs" :as ipfs] , running :app build

andrewzhurov19:06:54

shadow-cljs info

shadow-cljs - config: /home/user1/projects/re-frame/shadow-cljs.edn
openjdk version "17.0.5" 2022-10-18
OpenJDK Runtime Environment (build 17.0.5+0-adhoc..source)
OpenJDK 64-Bit Server VM (build 17.0.5+0-adhoc..source, mixed mode, sharing)

=== Version
jar:            2.17.5
cli:            2.17.5
deps:           1.3.2
config-version: 2.17.5

=== Paths
cli:     /home/user1/projects/re-frame/node_modules/shadow-cljs/cli/dist.js
config:  /home/user1/projects/re-frame/shadow-cljs.edn
project: /home/user1/projects/re-frame
cache:   .shadow-cljs

=== Java

=== Source Paths

andrewzhurov19:06:55

Running it via cider, cider print:

;;  Startup: /home/user1/.guix-home/profile/bin/npx shadow-cljs -d nrepl/nrepl:1.0.0 -d cider/cider-nrepl:0.29.0 -d cider/piggieback:0.5.2 server
;;
;; ClojureScript REPL type: shadow
;; ClojureScript REPL init form: (do (require '[shadow.cljs.devtools.api :as shadow]) (shadow/watch :app) (shadow/nrepl-select :app))

thheller19:06:05

the internet cannot find it either?

thheller19:06:24

could be that the package does something webpack specific that shadow-cljs does not support