8000 GitHub - alii/arc: ⌒ JavaScript on the BEAM · GitHub
[go: up one dir, main page]

Skip to content
aliiPublic

About

⌒ JavaScript on the BEAM

Topics

Resources

Contributing

Stars

232 stars

Watchers

3 watching

Forks

Repository files navigation

arc ⌒

JavaScript on the BEAM

js

Arc is a JavaScript engine and runtime written in Gleam. It implements the ECMAScript spec. On its own it has no effects, timers or I/O. The program that embeds Arc provides those, and Arc's embedding API makes that easy.

There's also Spark, a Node.js compatibility layer for Arc. Spark does provide I/O and timers, such as fs.readFile and setTimeout. You can think of Arc as the equivalent of JSC or V8, and Spark as the equivalent of Bun or Node.js.

Arc's API can change from one commit to the next, which is true of many engines. We recommend pinning to a commit SHA and upgrading on a regular schedule.

By default Arc interprets JavaScript, but it can also compile JavaScript to Erlang ahead of time (AOT). AOT has tradeoffs, and we don't recommend it for dynamic code, such as code generated at runtime. Arc runs on Erlang/OTP, and in the browser on our own fork of AtomVM compiled to WebAssembly. We forked AtomVM to make it faster in the browser.

Arc is tested against test262 on every commit:

test262 conformance chart



Arc uses the Mozilla Public License, Version 2.0.

About

⌒ JavaScript on the BEAM

Topics

Resources

Contributing

Stars

232 stars

Watchers

3 watching

Forks

Contributors

Languages

0