Compare Revisions

Using web workers

Revision 407861:

Revision 407861 by Sheppy on

Revision 437249:

Revision 437249 by Rob W on

Title:
Using web workers
Using web workers
Slug:
Web/Guide/Performance/Using_web_workers
Web/Guide/Performance/Using_web_workers
Tags:
"Workers","Firefox","Gecko 1.9.1","HTML5","JavaScript","NeedsTechnicalReview"
"Workers","Firefox","Gecko 1.9.1","HTML5","JavaScript","NeedsTechnicalReview"
Content:

Revision 407861
Revision 437249
n8      <span class="seoSummary">Dedicated Web Workers provide a sin8      <span class="seoSummary">Dedicated Web Workers provide a si
>mple means for web content to run scripts in background threads. >mple means for web content to run scripts in background threads. 
>Once created, a worker can send messages to the spawning task by >Once created, a worker can send messages to the spawning task by 
>posting messages to an event handler specified by the creator.</s>posting messages to an event handler specified by the creator.</s
>pan> However, they <strong>work within <a href="/en-US/docs/JavaS>pan> However, they <strong>work within <a href="/en-US/docs/JavaS
>cript/DedicatedWorkerGlobalScope" title="/en-US/docs/JavaScript/D>cript/DedicatedWorkerGlobalScope" title="/en-US/docs/JavaScript/D
>edicatedWorkerGlobalScope">another global context</a> different f>edicatedWorkerGlobalScope">another global context</a> different f
>rom the current window</strong> (using the <a href="/en-US/docs/D>rom the current window</strong> (using the {{ domxref("window") }
>OM/window" title="http://{{domxref(&quot;document.currentScript&q>} shortcut instead of {{ domxref("window.self","self") }} in orde
>uot;)}}"><code>window</code></a> shortcut instead of <a href="/en>r to get the current global scope within a {{ domxref("Worker") }
>-US/docs/DOM/window.self" title="/en-US/docs/DOM/window.self"><co>} will return, in fact, an error).
>de>self</code></a> in order to get the current global scope withi 
>n a {{ domxref("Worker") }} will return, in fact, an error). 
n647              3n647              {{CompatChrome(3)}}
648            </td>
649            <td>648            </td>
650              3.5 (1.9.1)
651            </td>649            <td>
650              {{CompatGeckoDesktop(1.9.1)}}
652            <td>651            </td>
653              10
654            </td>652            <td>
653              {{CompatIE(10)}}
655            <td>654            </td>
656              10.60
657            </td>655            <td>
656              {{CompatOpera(10.60)}}
658            <td>657            </td>
659              4658            <td>
659              {{CompatSafari(4)}}
n667              5n667              {{CompatChrome(3)}}
668            </td>
669            <td>668            </td>
670              ---
671            </td>669            <td>
670              {{CompatNo}}
672            <td>671            </td>
673              ---
674            </td>672            <td>
673              {{CompatNo}}
675            <td>674            </td>
676              10.60
677            </td>675            <td>
676              {{CompatOpera(10.60)}}
678            <td>677            </td>
679              5678            <td>
679              {{CompatSafari(5)}}
n687              13n687              {{CompatChrome(13)}}
688            </td>
689            <td>688            </td>
690              8
691            </td>689            <td>
690              {{CompatGeckoDesktop(8)}}
692            <td>691            </td>
693              10
694            </td>692            <td>
693              {{CompatIE(10)}}
695            <td>694            </td>
696              11.50
697            </td>695            <td>
696              {{CompatOpera(11.50)}}
698            <td>697            </td>
699              5.1698            <td>
699              {{CompatSafari(5.1)}}
t707              17 {{ property_prefix("webkit") }}t707              17 {{ property_prefix("webkit") }}<br>
708            </td>708              {{CompatChrome(21)}}
709            <td>709            </td>
710              18
711            </td>710            <td>
711              {{CompatGeckoDesktop(18)}}
712            <td>712            </td>
713              ---
714            </td>713            <td>
714              {{CompatNo}}
715            <td>715            </td>
716              ---
717            </td>716            <td>
717              {{CompatOpera(15)}}
718            <td>718            </td>
719              ---719            <td>
720              {{CompatSafari(6)}}
721            </td>
722          </tr>
723          <tr>
724            <td>
725              Global {{ domxref("window.URL", "URL") }}
726            </td>
727            <td>
728              10 {{as <code>webkitURL</code><br>
729              {{CompatChrome(23)}}
730            </td>
731            <td>
732              {{CompatGeckoDesktop(21)}}
733            </td>
734            <td>
735              {{CompatIE(11)}}
736            </td>
737            <td>
738              {{CompatOpera(15)}}
739            </td>
740            <td>
741              {{CompatNo}}

Back to History