playpit
v1.1.2
Published
A simple JS sandbox for Node environments
Downloads
3
Readme
Playpit
A simple JS sandbox for Node environments.
Installing
$ npm install --save playpit memory-fs
var MemoryFS = require('memory-fs'),
memoryFS = new MemoryFS(),
playpit = require('playpit').create(memoryFS);
memoryFS.writeFileSync('/test.js', 'console.log("Hello!")');
playpit.execute('require("/test.js");');
Hello!
Try the example
$ npm install
$ node demo/simple
File1
File2
Then
Index
End