Virtual Machine used to represent, run, and maintain the state of programs for Scratch 3.0
Find a file
2016-04-18 17:22:23 -04:00
src WIP 2016-04-18 17:20:30 -04:00
test WIP 2016-04-18 17:20:30 -04:00
.eslintrc WIP 2016-04-18 17:20:30 -04:00
.gitignore Initial commit 2016-04-08 13:10:37 -04:00
.travis.yml Add travis config 2016-04-18 17:22:23 -04:00
LICENSE Initial commit 2016-03-28 12:53:44 -04:00
Makefile WIP 2016-04-18 17:20:30 -04:00
package.json WIP 2016-04-18 17:20:30 -04:00
README.md Add travis config 2016-04-18 17:22:23 -04:00
TRADEMARK Initial commit 2016-03-28 12:53:44 -04:00
vm.js WIP 2016-04-18 17:20:30 -04:00
vm.min.js WIP 2016-04-18 17:20:30 -04:00
webpack.config.js WIP 2016-04-18 17:20:30 -04:00

scratch-vm

Build Status

Installation

npm install scratch-vm

Setup

var VirtualMachine = require('scratch-vm');
var vm = new VirtualMachine();

// Block events

// UI events

// Listen for events

Standalone Build

make build
<script src="/path/to/vm.js"></script>
<script>
    var vm = new window.VirtualMachine();
    // do things
</script>

Testing

make test
make coverage
make benchmark