diff options
Diffstat (limited to 'files/zh-cn/web/javascript/reference/functions/get/index.html')
-rw-r--r-- | files/zh-cn/web/javascript/reference/functions/get/index.html | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/files/zh-cn/web/javascript/reference/functions/get/index.html b/files/zh-cn/web/javascript/reference/functions/get/index.html index 5264abb7a5..613bb86276 100644 --- a/files/zh-cn/web/javascript/reference/functions/get/index.html +++ b/files/zh-cn/web/javascript/reference/functions/get/index.html @@ -48,7 +48,7 @@ translation_of: Web/JavaScript/Reference/Functions/get <h2 id="示例">示例</h2> -<h3 id="Example_Defining_a_getter_with_the_get_operator" name="Example:_Defining_a_getter_with_the_get_operator">在新对象初始化时定义一个getter</h3> +<h3 id="Example_Defining_a_getter_with_the_get_operator">在新对象初始化时定义一个getter</h3> <p>这会为<code>obj</code>创建一个伪属性<code>latest</code>,它会返回<code>log</code>数组的最后一个元素。</p> @@ -63,7 +63,7 @@ console.log(obj.latest); // "test".</pre> <p>注意,尝试为<code>latest</code>分配一个值不会改变它。</p> -<h3 id="Example_Deleting_a_getter_using_the_delete_operator" name="Example:_Deleting_a_getter_using_the_delete_operator">使用<code>delete</code>操作符删除 getter</h3> +<h3 id="Example_Deleting_a_getter_using_the_delete_operator">使用<code>delete</code>操作符删除 getter</h3> <p>只需使用 <code><a href="/zh-CN/docs/Web/JavaScript/Reference/Operators/delete">delete</a></code>,就可删除 getter:</p> @@ -161,7 +161,7 @@ console.log( <p>{{Compat("javascript.functions.get")}}</p> -<h2 id="See_also" name="See_also">相关链接</h2> +<h2 id="See_also">相关链接</h2> <ul> <li><a href="/en-US/docs/Web/JavaScript/Reference/Functions/set">setter</a></li> |