{code:title=mylib.js}
mylib = { abc: 3 }
{code:title=other.js}
other = { def: 17 }
{code:title=co.edn}
{:foreign-libs [{:file "mylib.js"
:provides ["my-lib"]
:requires ["other-lib"]}
{:file "other.js"
:provides ["other-lib"]}]}
Working, with browser REPL:
$ clj -m cljs.main -co co.edn -r
ClojureScript 1.10.339
cljs.user=> (require 'my-lib)
cljs.user=> js/other
#js {:def 17}
Faling with Node:
$ clj -m cljs.main -co co.edn -re node -r
ClojureScript 1.10.339
cljs.user=> (require 'my-lib)
nil
cljs.user=> js/other
repl:13
throw e__6464__auto__;
^
ReferenceError: other is not defined
...