mfikes
Joined 12 years ago
Joined 12 years ago
This stuff is arguably just an initial foray into the embedded world. You could imagine a Clojure dialect or compiler that emits WASM, or C, or even native code.
Perhaps a more sophisticated approach could be devised involving "faulting in" ClojureScript standard library functions on demand as they are used, and by doing this use less RAM and reduce startup latency. If that were done, things would run on a broader range of chips (less RAM needed).
I created the board for an upcoming Clojure/north 2020 talk https://clojurenorth.com/mike-fikes.html
But, your assessment is correct... the software is definitely the interesting bit (the challenges associated with getting ClojureScript to run on that hardware, with a REPL, etc.)
When Lisping existed (it is evidently no longer available), I was never really motivated to use it to develop code with Replete.
https://news.ycombinator.com/item?id=11658418
and you could edit text in Lisping and send it to Replete for evaluation. (The generic hooks still exist in Replete, so in theory other apps could do the same.)
(require ‘replete.http)
in order to load the code for that namespace.You should be able to copy output by pressing on a history row.
They have hugely different applications, but at a certain level, they look like the same language.
Replete iOS was one of the first applications of self-hosted ClojureScript (around 2015, the first time we could evaluate ClojureScript forms directly on iOS, no JVM in sight).
Just recently Replete was ported to Android, via some amazing work of Roman Liutikov.
It is all open source, for those interested in how it works: https://github.com/replete-repl/
If you would like your JavaScript to be derived from ClojureScript, and you would like a live REPL experience, then Ambly can be used for that.
An example library that uses this technique to drive a native iOS app is https://github.com/mfikes/goby
I've also had a separate commercial in the iOS App Store based on ClojureScript since 2014. (This pre-dated React Native, even, and is based on Goby.)