This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-07-05
Channels
- # announcements (1)
- # asami (21)
- # aws (19)
- # babashka (37)
- # beginners (38)
- # clj-kondo (7)
- # clj-otel (8)
- # clojure (29)
- # clojure-europe (54)
- # clojure-nl (3)
- # clojure-spec (2)
- # clojure-uk (2)
- # clojurescript (15)
- # conjure (1)
- # data-science (1)
- # datomic (21)
- # emacs (6)
- # events (3)
- # figwheel-main (1)
- # gratitude (13)
- # holy-lambda (11)
- # joyride (6)
- # klipse (3)
- # malli (14)
- # missionary (26)
- # nbb (31)
- # omni-trace (2)
- # pathom (3)
- # reagent (1)
- # reitit (1)
- # releases (1)
- # shadow-cljs (24)
- # sql (27)
- # tools-deps (4)
- # vim (21)
@borkdude I notice that some of the examples have nbb
in package.json and others do not. What's the general advice? Install it globally each time to get the updates or pin it to an (always old :rolling_on_the_floor_laughing: ) version?
My preference is to not install anything from npm globally and always run executables from project node_modules
with npx
. It’s a way to suffer 3% less JS-fatigue
If you install nbb locally, this is the fastest way to run it, if you care about startup time:
node_modules/.bin/nbb -e '(+ 1 2 3)'
isn’t it just a “normal” js runtime?
sci should work with it just fine
Yeah like #bebo this could be another thing. Performance numbers look nice and interestingly uses javascriptcore not v8
still feels kind a “yet another SPA framework every hour” situation few years ago 🙂 but for now it is “yet another JS runtime” just two weeks ago I found this - https://hermesengine.dev/
Yeah pretty much. True for the whole js ecosystem I feel. I'm just thinking where and how more clj(s) can be snuck into 😆
Also the current trend seems to be with things like jsx, ts etc is to compile on the fly and not precompile. Both deno and bun favour this.
So, this works in bun:
// loadFile is silently failing in bun, so we use loadString instead:
import { loadString } from 'nbb'
const code = await Bun.file('index.cljs').text();
await loadString(code);
> Where did you hear about bun? From the same nvim person I told you about, also a name in js/ts world from Netflix 😄 he was doing a live hack on it yesterday before it got open sourced
do you see any significant perf difference? this is a different js engine after all
startup with bun run nbb
is much faster than say npx nbb
. Haven't measured actually performance. Going to try the loop example now
right, i guess the focus is on fast startup for edge computing than runtime perf
is it in the bb ballpark for startup times 😛 ?