Now that we have the web worker file, we need to call it from an HTML page.
The following lines checks if the worker already exists, if not - it creates a new web worker object and runs the code in "demo_workers.js":
Then we can send and receive messages from the web worker.
Add an "onmessage" event listener to the web worker.
When the web worker posts a message, the code within the event listener is executed. The data from the web worker is stored in event.data.