Skip to content
SPECIFICTION
Get listed

ClojureScript vs Scala.js

ClojureScript

clojurescript.org

Scala.js

scala-js.org

Side by side

FigureClojureScriptScala.js
Price fromFreeFree
Free planYesYes
Free trial——
Open source——
WebYesYes
WindowsYesYes
macOSYesYes
LinuxYesYes
API—Yes
Self-hostedYes—
Plans published11
Spec score · Code Transpilers8.4 (#4)7.6 (#19)
LicenseUse and distribution are covered by the Eclipse Public License 1.0.The project repository states that Scala.js is distributed under the Apache License Version 2.0.

Plans

ClojureScript

  • ClojureScriptFree

ClojureScript pricing →

Scala.js

  • Scala.jsFree

Scala.js pricing →

In their own words

ClojureScript

ClojureScript is a compiler that turns Clojure code into JavaScript for client and embedded application development wherever JavaScript reaches. It brings Clojure data structures and constructs—including functional programming, macros, destructuring, and polymorphism—into JavaScript environments. Its output is compatible with Google Closure Compiler advanced compilation, which can minify output and eliminate dead code. REPL support enables interactive development and testing in a browser or Node.js; the quick start uses browser output by default and selects Node.js output with a target setting. ClojureScript supports both ClojureScript and JavaScript dependencies, with React demonstrated in the quick start. Listed build tools include shadow-cljs, Figwheel, Leiningen, and lein-cljsbuild. Editor resources cover Cursive, Emacs, VS Code, Light Table, Sublime Text, Vim, and Atom. Documentation includes compiler and REPL options, dependencies, advanced compilation, source maps, and JavaScript module support marked Alpha. The project is open source under the Eclipse Public License 1.0 and lists Linux, macOS, Windows, web, and self-hosted environments.

Visit clojurescript.org

Scala.js

Scala.js is a Scala-to-JavaScript compiler for building applications that run in browsers, Node.js, and serverless environments. The project also states that WebAssembly support is stable. Scala's strong typing can catch mistakes such as mixing strings and numbers or using misspelled method names, while editor support can flag type errors and show inline details about methods, arguments, return types, and documentation. The project describes incremental compilation with a 1–2 second turnaround; generated JavaScript for a full application starts at 45 kB gzipped. Scala.js can use JavaScript libraries and APIs through statically or dynamically typed access. Listed library integrations include React, Angular, Vue, Three.js, and Chart.js. Build tool options include sbt, scala-cli, Mill, and Gradle with a Scala.js plugin. Tutorials list Scala development tools and Node.js as prerequisites and recommend VS Code with Metals. Scala.js is free and distributed under the Apache License 2.0. Documentation points users to community support through Discord and Stack Overflow. The 1.22.0 release is not entirely backward source compatible with 1.21.x.

Visit scala-js.org