7. “A web worker is a
JavaScript that runs in the
background, independently
of other scripts, without
affecting the performance of
the page”
Web Hypertext Application Technology Working Group
(WHATWG)
12. Available Features
● The navigator object
● The location object (read-only)
● XMLHttpRequest
● setTimeout()/clearTimeout() and setInterval()/clearInterval()
● The Application Cache
● Importing external scripts using importScripts()
● Creating other web workers
13. Unavailable Features
● The DOM (it’s not thread-safe)
● The window object
● The document object
● The parent object
32. Limitations
● Don’t have DOM interaction
● Send a function into postMessage() is not allowed
● High memory cost
● postMessage can only transmit strings
● Not intended to be used in big numbers