JavaScript back and Forth

Aliaksei Chapyzhenka

JavaScript back and Forth

Aliaksei Chapyzhenka drom.io/fday15

We turn out water into wine
It's something we do all the time
It doesn't cost a single dime
And it's beautiful...

Crash Test Dummies

Forth is everywhere

  • Forth runs everywhere
  • JavaScipt is new "everywhere"

    Some JavaScript facts

    JavaScript AST

    JavaScript arithmetic

    case 1: Forth interpreter in JavaScript

    Repo and Demo

    Forth in JS -- challenges

    case 2: JavaScript to Forth

    Demo

    case 3: CodeMirror

    CodeMirror is a versatile text editor implemented in JavaScript for the browser

    Supports 100+ languages including Forth

    Runs lightweight Forth interpreter to do proper coloring

    Conclusions