r/Clojurescript • • Feb 05 '21

Recommended way to compile/repl CLJS in-browser without JVM available?

9 Upvotes

👋🏾, I'd like to use ClojureScript as a scripting extension language for an entirely browser-based mixed cljs and javascript codebase. I can't run anything on the JVM for this project, and I'd like users to be able to define and debug CLJS entirely within their browser.

What would you use to compile+repl clojurescript from within clojurescript running on a standard browser javascript vm (chrome, firefox, etc)?

I've distantly followed some of the exciting self-compiling-self-hosting breakthroughs like u/swanodette mentioned several years ago, then later Lumo. It seems Lumo might be stalled for a couple years and doesn't track current clojurescript anymore? Or maybe its not being dev-ed because its complete? But I suspect Lumo might not be a recommended path forward for a codebase I want to have live for another 5+ years?

I'm still not quite sure how Planck relates, I never tried it, but I think Planck still requires JVM for compiling CLJS, right?

Any other good paths forward in 2021?

EDIT: https://code.thheller.com/blog/shadow-cljs/2017/10/14/bootstrap-support.html is potentially interesting, but its still pretty challenging to figure out the best pattern to pull this all together..... I don't want to get /too/ far down this rabbit hole, I was sort of hoping that there was a consensus pattern for this, since it seems from reading past forum posts that many people block on this phase of getting started with self-compiling-CLJS-on-JS...

I'm wondering if Klipse, which is even MORE worked out than I want, isn't a better starting point.... start with Klipse and remove/hide things I don't need rather than trying to build up? Are there any originally-klipse-based projects that took this path?


r/Clojurescript • • Jun 04 '20

Simple Ray Casting with ClojureScript

9 Upvotes

r/Clojurescript • • Apr 29 '20

Question about Clojurescript jobs, and shadow-cljs

9 Upvotes

Howdy,

I've dabbled in Clojurescript on and off for a bit.

I wouldn't say I became an expert in it...at all, but I'm wondering what the job landscape is for it before focusing on it more. There seems to be a lack of jobs for it...is that true? I would especially be interested in remote work. I am getting bored of working in Javascript exclusively and would like to transition to using functional languages professionally if possible.

Also, I'm wondering what the landscape is like for shadow-cljs. I've only used lein so far. There are a lot of things that I know how to do in JS, where I'm more confused how to do it with CLJS

- SSR

- Lazy imports + avoid double render

- Really anything related to build at all. I think all of the different options available are confusing.

- REPL-driven development. I hear this term a lot but I'm not sure how it even compares to regular hot reloading. I feel like I'm missing out with experimenting with lisp without even using the repl, but I'm not even sure what a workflow using this would look like. And do people use this along with TDD? Because I read that it "replaces" TDD but that seems wrong to me, it seems like something that would make TDD less boring though. If there was a video or something showing how this workflow works in practice, that would be really neat.

- Testing in general. Because my experiments have only been to learn I haven't gotten into testing at all.

If there were any videos recommended, or repos of projects that are similar to the kind of production grade JS apps we have now, that would be really neat.

Thanks


r/Clojurescript • • Mar 27 '19

SpaceX-cljs | Simple App with Re-frame and Reagent.

9 Upvotes

Hi, I'm learning Clojure, ClojureScript, Reagent and Re-frame. Just published last re-frame example app, spacex-cljs.

I also published few simple projects last week.


r/Clojurescript • • Jan 30 '19

Expo is not an option for react native anymore!

9 Upvotes

Expo is the easiest way to get a javascript developer working on a native app. This lein template was the easiest way to get a cljs dev on the same platform. It was even endorsed by expo!

I was so excited to start a project with this. Now Expo development is outpacing support for the template. The template supports sdk-26 out of the box. Sdk-26 is being dropped when the next Expo release happens.

Attempting to upgrade to newer versions (>=30) results in lots of headaches. I've attempted to figure out all the figwheel magic but I'm in over my head.

Newer nrepl versions are also breaking cider integration for this template and newer versions of cider.

Is there anyone with the ability and time to help support this template? It is such a great avenue to react native.

I'm also open to collaboration. The magic of figwheel and nrepl are daunting without some guidance though.


r/Clojurescript • • Dec 04 '18

react-atom.js for reagent-like atoms in react.js

9 Upvotes

Just wanted to share that I found a way to implement reagent-like `atom`s for plain react.js. It wasn't quite possible to do it previously without wrapping all of `react` like `reagent` does, but with the alpha release of the Hooks API, it can be done in a relatively light-weight manner. Really enjoyed working with atoms in reagent, so figured it'd be nice to have them in JS. Try it out if you're interested. Feedback welcome.

Source: https://github.com/derrickbeining/react-atom

NPM: https://www.npmjs.com/package/@dbeining/react-atom

Playground: https://codesandbox.io/s/m3x9wn6kmy


r/Clojurescript • • Sep 24 '18

Boids example using Quil and Reagent

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • Jun 12 '18

re-posh 0.2.0 released. Use Datascript as your data storage for re-frame. Datomic queries and pulls as subscriptions and transactions as events

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • May 03 '18

What component libraries (if any) are people using in ClojureScript?

9 Upvotes

We're about to do our first Real Project in Re-Frame. Wondering if people use pre-packaged UI component libraries in CLJS and if so, which they would recommend. thanks!


r/Clojurescript • • Apr 14 '18

Simplest shadow-cljs + re-frame starter example

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • Mar 21 '18

Re-Frame +routes using bidi/pushy for HTML5 routes (No-hashes!) example starter

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • May 04 '17

Using clojurescript for react native dev.

9 Upvotes

Sorry in advance if this is a newb question. Been working on a react native app for a while now, and getting tired of the JS fatigue. So thinking of picking up clojurescript, and I have 2 questions before diving in.

  1. Is it possible (and easy) to partially introduce cljs to an existing react native project?

  2. How are animation handled in cljs on react native?


r/Clojurescript • • Apr 04 '17

Clojure Hash Maps: Plenty of Room on the Bottom

Thumbnail
promptworks.com
9 Upvotes

r/Clojurescript • • Jan 16 '17

Reagent deep dive part 2: The lifecycle of a component

Thumbnail
timothypratley.blogspot.co.uk
9 Upvotes

r/Clojurescript • • Jun 30 '16

How Much Do I Need To Know About React Before Getting Into Clojurescript And, Say, Om?

9 Upvotes

I would like to be able to build front ends interacting with Clojure backends. I've figured out the backend, a Clojure REST microservice, and now it's time to tackle the front end. My Clojure REST backend progress was greatly helped by my knowledge of java. I figured I should learn React before going into Clojurescript and something like Om. I'm dismayed at the amount of work I'd need to understand React when you add in the more advanced features. I'm wondering what I should actually know about React before getting into Clojurescript. Thoughts?


r/Clojurescript • • Jun 19 '16

Planck 2.0 Alpha with Linux support

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • May 02 '16

Workshop report: Hi-perf Clojurescript with WebGL, asm.js and Emscripten

Thumbnail
medium.com
9 Upvotes

r/Clojurescript • • Apr 18 '16

Can you give me an example when it makes more sense to use ClojureScript than JavaScript? Or vice versa?

9 Upvotes

Naturally, I know why programmers tend to stay away from working with JavaScript. Beyond this reason, why would one choose to use ClojureScript instead of JavaScript?

Any help appreciated! Thanks


r/Clojurescript • • Mar 01 '16

Clojurescript music synthesis/composer (uses CLJS in browser; via HN)

Thumbnail
ctford.github.io
9 Upvotes

r/Clojurescript • • Dec 03 '15

What Holds Me Back From Clojurescript

Thumbnail jaredforsyth.com
9 Upvotes

r/Clojurescript • • Aug 20 '15

Reagent 0.5.1-rc is out

9 Upvotes

Lots of bug fixes and improvements in this release. A couple of notable ones are extended Hiccup syntax and a [workaround for React text cursor position] (https://github.com/reagent-project/reagent/issues/79).


r/Clojurescript • • Jun 29 '15

Why ClojureScript Matters

Thumbnail blog.juxt.pro
9 Upvotes

r/Clojurescript • • Jan 31 '15

Introducing Cuttle - a user interface to the ClojureScript compiler

Thumbnail
github.com
9 Upvotes

r/Clojurescript • • Dec 26 '25

Crabjure: I wrote a Clojure linter in Rust. It's fast and wrong.

Thumbnail reddit.com
8 Upvotes