cljs-dev

ClojureScript compiler & std lib dev, https://clojurescript.org/community/dev
2020-04-20T08:58:12.168100Z

> Symbol Support 🎉

souenzzo 2020-04-20T11:48:19.170800Z

I'm checking the fact at Output size minimized for trivial "Hello World" programs and I see that some releases of cljs has a output way larger then other ones. I will try to write a script and build a matrix . (manual result in first response on this thread. Do not use this thread!)

souenzzo 2020-04-20T11:48:27.170900Z

$ cat src/foo/bar.cljs 
(ns foo.bar)

(.log js/console "ok")

# build: clj -Sdeps '{:deps {org.clojure/clojurescript {:mvn/version "1.10.439"}}}}' -m cljs.main --optimizations advanced --output-to 1.10.439.js -c foo.bar
# du -h master.js 1.10.597.js 1.10.520.js 1.10.439.js 1.10.63.js 
4,0K	master.js
96K	1.10.597.js
8,0K	1.10.520.js
8,0K	1.10.439.js
92K	1.10.63.js

dnolen 2020-04-20T12:50:52.171400Z

@souenzzo let's not use threads in this channel

dnolen 2020-04-20T12:51:20.171800Z

@souenzzo writing a matrix for the change isn't that interesting in my opinion

dnolen 2020-04-20T12:51:55.172600Z

it's just a test for artificially trivial programs - a very small number of users would rely on this aspect of DCE

dnolen 2020-04-20T12:53:18.173600Z

@mfikes thanks! I might edit that to add some more rationale for the removals of the REPLs and a path for alternatives (and relevant new changes to make that easier)

dnolen 2020-04-20T13:25:19.173900Z

@mfikes fixed CLJS-3230

👍 3
dnolen 2020-04-20T17:53:51.178400Z

@alexmiller does Clojure clone the array passed to seq? https://clojure.atlassian.net/browse/CLJS-3231

dnolen 2020-04-20T17:57:28.179900Z

hrm yeah I was pretty sure Clojure didn't - I don't think this is a bug

2020-04-20T18:43:05.181200Z

Hi, I'm pretty thrilled by krell (https://github.com/vouch-opensource/krell). Looks very minimal which I like. But I have some difficulties requiring installed node modules. For example: I try to (require '@react-navigation/bottom-tabs) (also without the @) but to no avail. The doc reads "Because Krell uses the ClojureScript compiler to index node_modules, you can idiomatically require anything you've installed via yarn or npm just like any ClojureScript library." but I cannot make it work. Any help would be great. Completion on the REPL with (require ' + TAB shows many things but not the node module. Am I missing something? #noob

2020-04-20T18:44:04.181600Z

Yes, I already restarted Metro.

dnolen 2020-04-20T18:51:06.181900Z

@axel that's not a valid symbol

dnolen 2020-04-20T18:52:02.183100Z

however we changed ClojureScript a while back to support strings for the library name not just symbols

dnolen 2020-04-20T18:53:44.184800Z

(ns foo.core (:require ["@react-navigation/bottom-tabs" :as rn-bottom-tabs])) or something like that

dnolen 2020-04-20T18:55:25.185700Z

@axel also I'm answering Krell specific questions in #cljsrn

dnolen 2020-04-20T18:56:29.186600Z

(require '"@react-navigation/bottom-tabs") should also work though we should probably enhance this to avoid the quoting since not really necessary here

2020-04-20T20:36:31.187600Z

Thanks a lot @dnolen. I will try this.