I have the following code
w = new Worker('<?php echo base_url(); ?>'+"assets/js/web_worker.js");
w.postMessage({base_url:BASE_URL,site_url:SITE_URL});
This runs on each page load and the worker could take awhile to run task.
- Will the worker continue to run if I navigate away from page after I start it?
- It seems the worker will start each page load regardless if it is finished. How do a see if the worker is running and NOT start another worker?