Stats

331 Contributors: 10 Monday, June 12, 2017
Licensed under: CC-BY-SA
Not affiliated with Stack Overflow
Rip Tutorial: riptutorial@gmail.com
Roadmap: roadmap
Download eBook

Workers

Download javascript eBook

Syntax

  • new Worker(file)
  • postMessage(data, transfers)
  • onmessage = function(message) { /* ... */ }
  • onerror = function(message) { /* ... */ }
  • terminate()

Remarks

  • Service workers are only enabled for websites served over HTTPS.

Related Examples