Simple execution context for node and the browser. In node it just creates a new
runInContext in that context and in the browser it creates an
iframe and hangs on to it until destroy is called.
npm install context-eval
Use with browserify or node.
to run the tests:
test in browsers:
npm install karma -g karma start
sandbox (optional) is an object that would be shallowly copied into the execution context.
parentElement (optional) is an element where the iframe can appended to, defautls to
Evaluates code and returns result.
Does nothing in node but removes iframe in browser.