Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8f21e30

Browse files
authored
fix: 移除 private 相关部分示例代码内多余注释,避免误导 (xcatliu#206)
1 parent ffe0330 commit 8f21e30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

advanced/class.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ class Animal {
179179
}
180180

181181
let a = new Animal('Jack');
182-
console.log(a.name); // Jack
182+
console.log(a.name);
183183
a.name = 'Tom';
184184

185185
// index.ts(9,13): error TS2341: Property 'name' is private and only accessible within class 'Animal'.

0 commit comments

Comments
 (0)