Skip to content

Commit 7073dfa

Browse files
committed
add missing semicolon
Signed-off-by: Bo-Yi Wu <[email protected]>
1 parent 143bda7 commit 7073dfa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

doc/zhtw/object/prototype.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
## Prototype
2-
2+
33
JavaScript 不包含原本繼承的模型。然而它使用的是*原型*模型*
44

55
然而常常有人提及 JavaScript 的缺點,就是基於原本繼承模型比類繼承更強大。
@@ -28,11 +28,11 @@ JavaScript 不包含原本繼承的模型。然而它使用的是*原型*模型*
2828
// 修正 Bar.prototype.constructor 為 Bar 本身
2929
Bar.prototype.constructor = Bar;
3030

31-
var test = new Bar() // 開啟一個新的實例
31+
var test = new Bar(); // 開啟一個新的實例
3232

3333
// 原型鏈
3434
test [instance of Bar]
35-
Bar.prototype [instance of Foo]
35+
Bar.prototype [instance of Foo]
3636
{ foo: 'Hello World' }
3737
Foo.prototype
3838
{ method: ... }

0 commit comments

Comments
 (0)