Sandbox for running unsafe, user-entered code. No access to global scope/window/document/other stuff, just API specified by the host.
console.log(...) // for printing and debugging
draw_rect(x, y, w, h) // just a test function to test interaction with host
get_foo() // another test function that returns instance of Foo