mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-12-17 08:26:32 +08:00
语法高亮,滚动条美化,设置页面调整
This commit is contained in:
@@ -4,8 +4,8 @@
|
||||
<div><iframe class="interactive interactive-js" frameborder="0" height="250" src="https://interactive-examples.mdn.mozilla.net/pages/js/atomics-store.html" width="100%"></iframe></div>
|
||||
<p class="hidden">The source for this interactive example is stored in a GitHub repository. If you'd like to contribute to the interactive examples project, please clone <a class="external" href="https://github.com/mdn/interactive-examples" rel="noopener">https://github.com/mdn/interactive-examples</a> and send us a pull request.</p>
|
||||
<h2 id="语法">语法</h2>
|
||||
<pre class="syntaxbox">Atomics.store(typedArray, index, value)
|
||||
</pre>
|
||||
<pre><code class="language-javascript">Atomics.store(typedArray, index, value)
|
||||
</code></pre>
|
||||
<h3 id="参数">参数</h3>
|
||||
<dl>
|
||||
<dt><code>typedArray</code></dt>
|
||||
@@ -24,10 +24,10 @@
|
||||
<li>抛出一个<a href="Reference/Global_Objects/RangeError" title="RangeError对象标明一个错误,当一个值不在其所允许的范围或者集合中。"><code>RangeError</code></a>异常, 如果 <code>index</code> 在 <code>typedArray</code>中越界了。</li>
|
||||
</ul>
|
||||
<h2 id="示例">示例</h2>
|
||||
<pre class="brush: js">var sab = new SharedArrayBuffer(1024);
|
||||
<pre><code class="language-javascript">var sab = new SharedArrayBuffer(1024);
|
||||
var ta = new Uint8Array(sab);
|
||||
|
||||
Atomics.store(ta, 0, 12); // 12</pre>
|
||||
Atomics.store(ta, 0, 12); // 12</code></pre>
|
||||
<h2 id="规范">规范</h2>
|
||||
<table class="standard-table">
|
||||
<tbody>
|
||||
|
||||
Reference in New Issue
Block a user