Quickstart

Up and running in minutes

Install the vexascript npm package, write your first .vx file, add the VS Code extension for a full editor experience, and optionally embed a live Monaco editor in your own site.

1

Install the CLI

Install the vexascript package globally. The vexa binary becomes available immediately.

npm install -g vexascript
vexa --version

Alternatively, run it without installing via npx:

npx vexascript run hello.vx
2

Write your first file

Create a hello.vx file. VexaScript is a TypeScript superset — valid TypeScript is valid VexaScript.

class Greeter(val name: string) {
  fun greet() => `Hello, ${name}!`
}

val g = Greeter("world")
console.log(g.greet())

Run it directly or compile to JavaScript:

vexa run hello.vx
vexa build hello.vx -o dist/hello.js
3

Install the VS Code extension

The official extension gives you diagnostics, quick fixes, go-to-definition, hover docs, and completions as you type.

Once installed, open any .vx file and the language server starts automatically. Use the syntax reference or the CLI guide to explore further.

4

Run tests

Test files use the .test.vx suffix. The test and assert helpers are available without any import.

test("arithmetic", () => {
  assert(1 + 1 == 2)
  assert(2 * 3 == 6)
})

Run all tests under the current directory, or pass specific paths:

vexa test
vexa test src/math.test.vx
5

Embed Monaco in your site

The website bundle ships embeddable Monaco-powered editors. Drop a live, editable VexaScript snippet into any docs page or product demo.