This shows how to require ES modules in a node script which is itself compiled as an ES module by shadow. I made this to verify if nbb's way of requiring ES modules aligns with other tools that accomplish the same using the CLJS compiler.
Build with npx shadow-cljs compile script
.
Run with node out/script.js
. It will print something like:
#js {:columns 202, :rows 45}
[Function: Spinner]