aboutsummaryrefslogtreecommitdiff
path: root/files/zh-cn/web/javascript/reference/global_objects/generator/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'files/zh-cn/web/javascript/reference/global_objects/generator/index.html')
-rw-r--r--files/zh-cn/web/javascript/reference/global_objects/generator/index.html6
1 files changed, 3 insertions, 3 deletions
diff --git a/files/zh-cn/web/javascript/reference/global_objects/generator/index.html b/files/zh-cn/web/javascript/reference/global_objects/generator/index.html
index 612024ca88..f7e4fc037b 100644
--- a/files/zh-cn/web/javascript/reference/global_objects/generator/index.html
+++ b/files/zh-cn/web/javascript/reference/global_objects/generator/index.html
@@ -65,13 +65,13 @@ console.log(gen.next().value);
<dl>
<dt><code>Generator.prototype.next() </code>{{non-standard_inline}}</dt>
- <dd>返回 {{jsxref("Operators/yield", "yield")}} 表达式产生的值. 与ES2015 生成器对象的<span style="font-family: courier,andale mono,monospace;">next()方法对应</span>.</dd>
+ <dd>返回 {{jsxref("Operators/yield", "yield")}} 表达式产生的值. 与ES2015 生成器对象的next()方法对应.</dd>
<dt><code>Generator.prototype.close()</code> {{non-standard_inline}}</dt>
- <dd>关闭生成器,因此执行该函数后调用<code>next()函数时将会抛出</code> {{jsxref("StopIteration")}} 错误. 与ES2015 生成器对象的<span style="font-family: courier,andale mono,monospace;">return()方法对应</span>..</dd>
+ <dd>关闭生成器,因此执行该函数后调用<code>next()函数时将会抛出</code> {{jsxref("StopIteration")}} 错误. 与ES2015 生成器对象的return()方法对应..</dd>
<dt><code>Generator.prototype.send()</code> {{non-standard_inline}}</dt>
<dd>用于将值发送到生成器。 该值由 {{jsxref("Operators/yield", "yield")}} 表达式返回, 并且返回下一个 {{jsxref("Operators/yield", "yield")}} 表达式产生的值. <code>send(x)</code> 对应于ES2015生成器对象中的 <code>next(x)</code></dd>
<dt><strong><code>Generator.</code></strong><code>prototype.</code><strong><code>throw()</code> </strong> {{non-standard_inline}}</dt>
- <dd>向生成器抛出错误. 与ES2015 生成器对象的<span style="font-family: courier,andale mono,monospace;">throw()方法对应</span>.</dd>
+ <dd>向生成器抛出错误. 与ES2015 生成器对象的throw()方法对应.</dd>
</dl>
<h3 id="旧生成器对象示例">旧生成器对象示例</h3>