From aa87e67fce3fb2c7d4180303e622896ca3f00994 Mon Sep 17 00:00:00 2001 From: YOONBYEONGIN Date: Tue, 23 Apr 2019 22:29:19 +0900 Subject: [PATCH] =?UTF-8?q?return=EA=B0=92=EC=9D=84=20=EB=B3=80=EC=88=98?= =?UTF-8?q?=EB=A1=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 3이 아니라 this.vertices를 return하는게 더 어울리는것 같습니다. --- 04-interface-and-class/class-advanced/accessors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/04-interface-and-class/class-advanced/accessors.md b/04-interface-and-class/class-advanced/accessors.md index 199ef22..dc0c15d 100644 --- a/04-interface-and-class/class-advanced/accessors.md +++ b/04-interface-and-class/class-advanced/accessors.md @@ -42,7 +42,7 @@ class Shape { constructor (public vertices: number) { } get vertices(): number { console.log('Vertices getter called.'); - return 3; + return this.vertices; } } const triangle: Shape = new Shape(3);