O'Reilly logo

HTML5: Your visual blueprint™ for designing rich web pages and applications by Adam McDaniel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

INTRODUCING WEB WORKERS

With Web Workers, you can split computationally expensive tasks into separate JavaScript threads and communicate to them independently from the main JavaScript program actually running in a web page.

The workers themselves are clones of the JavaScript runtime environment, so nearly all built-in methods and functions are available, but there are some restrictions on what they can do. For example, a worker cannot access the normal browser window directly, including the window and document objects, nor the DOM itself, so its perspective on the browser’s HTML rendering process is nil. Web Workers do have access to the navigator and location objects, though, so they can discover what the browser is running and its current URL; ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required