This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-05-17
Channels
- # announcements (10)
- # aws (10)
- # babashka (11)
- # beginners (77)
- # calva (9)
- # cider (10)
- # cljdoc (7)
- # cljs-dev (47)
- # clojure (47)
- # clojure-uk (4)
- # clojurescript (87)
- # community-development (15)
- # conjure (14)
- # core-async (25)
- # cursive (6)
- # fulcro (6)
- # helix (3)
- # joker (2)
- # nrepl (1)
- # off-topic (1)
- # pathom (9)
- # pedestal (6)
- # re-frame (22)
- # reitit (15)
- # shadow-cljs (26)
- # spacemacs (16)
- # testing (2)
- # tools-deps (12)
- # uncomplicate (10)
- # xtdb (22)
Funny thing, Rust's tool for building into WASM also has target bundler
https://rustwasm.github.io/docs/wasm-bindgen/reference/deployment.html#bundlers
> Currently the only known bundler known to be fully compatible with wasm-bindgen is webpack.
@dominicm sorry mies is no longer the bar - using ClojureScript directly - it used to be that wasn't that practical but with cljs.cli
not really true anymore. Are you calling cljs.closure/build
? If so not really recommended anymore cljs.build.api/build
and a refusal to break the old way - pretty sure if you can pass nil
for 1st arg if you don't care
re: optimizing :bundle-cmd
I don't really like that idea so much, but mostly because I think the class of things you might want to customize is larger than this particularly issue. Also any optimization here is bound to be a bit ugly. :bundle-cmd
can be arbitrary
so why not a command that first checks if npm_deps.js
is equal to npm_deps.last.js
runs webpack if they're different, copies npm_deps.js
to npm_deps.last.js
@darwin that Blender / CLJS approach seems like a lot of effort - I don't see the advantage over Client/REPL strategy - with the later you can definitely have something working in a couple of weeks - and something great in a couple of months since you just reuse everything already in ClojureScript
since you're embedding anyway you have a lot of control you don't have in say React Native wrt. sync file loading for dev etc.
@roman01la I think the important thing here if alternative targets are going to succeed is to stop thinking about it as a giant project. In fact best to start with a toy - ClojureScript was a toy too at one point.
I would make a project that just attempts to generate Dart from ClojureScript - it doesn't need to do everything
if this is done as small steps over many months eventually all those little problems go away - and they go away for everyone - not just Dart
@dnolen the single arity version passes nil as the first argument, and that's what is broken.
https://babeljs.io/docs/en/babel-plugin-transform-es3-member-expression-literals could we do this when hitting a reserved name for es3?
re: optimizing :bundle-cmd
while folks can roll there own here, a lot of effort has gone into making incremental builds fast. The bundle target will be the default target at some point sooner or later and it would be a shame for everyones incremental build times to suffer behind a blunt approach.
one needn’t use or rely on :bundle-cmd
and can simply call their bundler from the command line whenever they want
one sticky point is the initial bundling that we need in order to launch the application, as files the bundler needs don’t exist yet
I haven't actually seen a bundler without watch support yet. Maybe that's the way to go.
oh it should be mentioned here that this is all said in the context of in process incremental builds and the responsiveness of hot-reloading
https://ask.clojure.org/index.php/9305/wrong-command-in-the-clojurescript-quick-start
What's the best way to run a repl in the project & test building against code? Or - what's your dev setup for the cljs codebase?