Skip to content

Added status msg from the worker function (param.fn) to a callback function (param.fn).#9

Open
gaugustin wants to merge 3 commits intovkiryukhin:masterfrom
gaugustin:master
Open

Added status msg from the worker function (param.fn) to a callback function (param.fn).#9
gaugustin wants to merge 3 commits intovkiryukhin:masterfrom
gaugustin:master

Conversation

@gaugustin
Copy link
Copy Markdown

I added an ability to send status msg from the worker function (param.fn) to a callback function (param.onmsg). I also added support for AMD module / Node module / browser or worker variable.

var param = {
fn: // <-- function to run in a thread;
args: // <-- function's arguments;
cb: // <-- callback function for fn terminated; can be anonymous
onmsg: // <-- callback function for "self.postMessage({ msg: });" out of fn
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant