Skip to content

Commit f13a2b5

Browse files
committed
docs: edit decorator
1 parent 546b9d3 commit f13a2b5

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

docs/decorator.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# 修饰器
22

3+
[说明] Decorator 提案经过了大幅修改,目前还没有定案,不知道语法会不会再变。下面的内容完全依据以前的提案,已经有点过时了。等待定案以后,需要完全重写。
4+
35
## 类的修饰
46

57
许多面向对象的语言都有修饰器(Decorator)函数,用来修改类的行为。目前,有一个[提案](https://github.com/tc39/proposal-decorators)将这项功能,引入了 ECMAScript。

sidebar.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
1. [async 函数](#docs/async)
2828
1. [Class 的基本语法](#docs/class)
2929
1. [Class 的继承](#docs/class-extends)
30-
1. [Decorator](#docs/decorator)
3130
1. [Module 的语法](#docs/module)
3231
1. [Module 的加载实现](#docs/module-loader)
3332
1. [编程风格](#docs/style)
3433
1. [读懂规格](#docs/spec)
3534
1. [ArrayBuffer](#docs/arraybuffer)
3635
1. [最新提案](#docs/proposals)
36+
1. [Decorator](#docs/decorator)
3737
1. [参考链接](#docs/reference)
3838

3939
## 其他

0 commit comments

Comments
 (0)