Skip to content

mbbill/JSC.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

fc2a917 · Oct 12, 2021

History

83 Commits
May 20, 2020
May 20, 2020
May 10, 2019
Oct 12, 2021
May 10, 2019
Apr 15, 2019
May 10, 2019
May 10, 2019
Sep 18, 2017
Sep 19, 2017
Oct 12, 2021
Sep 15, 2017
May 17, 2020
Apr 15, 2019

Repository files navigation

JSC.js is a JavaScript engine that can run on top of your browser's JavaScript engine. It's based on the JavaScript engine (JavaScriptCore) of WebKit and compiled to wasm with emscripten. Therefore, if you're using Safari, you are running its JavaScript engine on top of itself.

The size of JSC.wasm is around 4MB (compressed js and mem file).

Demo: Link

ScreenShot

Build

Preparation

  • install emscripten
  • install python, ruby, ninja, etc.
  • start a terminal.
  • go to emsdk installation path and run emsdk_env.bat
  • go to JSC.js folder and run prep_env.bat

Build with gn

> gn gen out --args="target_os=\"wasm\""
> ninja -C out

Build test shell on Windows

Usually, you don't need this but with the test shell, you can easily debug and test JSC.js on windows when there's no good debugger for JSC.js on wasm.

Preparation

  • install python, ruby, etc.
  • start a terminal.
  • install visual studio
  • run vcvarsall.bat amd64 in terminal

Build with gn

> gn gen out --args="target_os=\"win\""
> ninja -C out