background-worker
v0.1.2
Published
Execute tasks on Web Workers without seperate files.
Downloads
246
Readme
background-worker
Usage
var BackgroundWorker = require( 'background-worker' )
var worker = new BackgroundWorker()
worker.define( 'add', ( a, b ) -> a + b )
worker.run( 'add', [1, 2] ).then((res) -> {
res === 3
})
.finally( () -> worker.terminate() )
Execute tasks on web Workers without seperate files.
Partially made, with <3 at: