async-task
async-task copied to clipboard
Handling dependencies inside AsyncTask
How can I invoke a function defined in another module from inside AsyncTask. Whatever I require outside seems to be undefined inside. How can I require something inside?
If its webworker you have to use the webworker internal API for importing scripts: https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Using_web_workers#Importing_scripts_and_libraries
If you are using it in nodejs you use the standard require('foo/bar')