r/Clojurescript • u/reubano • May 11 '26
Js API for compiling
What is the recommended approach for compiling cljs into js via a js API? I want to write a vite plugin similar to https://www.npmjs.com/package/vite-plugin-coffee. It must be a js file though. With coffeescript, you can import it and call its compile method directly in js. Is there an equivalent for clojure? Ive seen lumo, planck, clavascript, shawdow, etc. but am not sure how to call compile in a js file.
1
Upvotes
View all comments
Show parent comment
1
u/reubano May 11 '26
It appears this plugin cheats by spawning a shell to call shadow-js. Guess that means there isnt a readily available js API.