Ink playground, "Maverick" 🦅
You can try the demo at play.dotink.co by running some included example programs.
Maverick's primary goal is to enable anyone to write and experiment with Ink programs without installing anything on their system. I had developed a version of the playground before that was backed by a sever-side evaluation service, but I didn't feel very secure publishing a remote code execution service to the open Internet, for obvious reasons.
eval(). This has the unfortunate side-effect of Ink programs being able to introspect and modify the surrounding web application, but this isn't too much of an issue, because if anything breaks, you can just reload the page!
Outside of the compiler, Maverick is a simple single-page web application built using Torus.
For example, we can type in
sort!(map([1, 2, 3], n => n * n)) to the REPL and execute it without importing
Because Maverick depends significantly on the September compiler, the repository is designed to be cloned side-by-side to the
Maverick uses a Makefile for development and build tasks. Simply running
static/ink/bundle.js. Other commands are as follows.
make fformats all non-vendored source code, including tests.
make truns all tests.
- There are several different build tasks, depending on what portion of the app you want to compile:
make build-libscompiles the common dependencies between September and Maverick into
make build-septembercompiles the September compiler source from the directory
make buildcompiles the Maverick application itself into the final bundle, assuming that the dependencies and September itself have been compiled.
make wwatches Maverick's source code for changes and recompiles them when they are changed. This is useful for iterating during development, and depends on entr.
Maverick is continuously deployed as a static site on Vercel, on every push to git branch