DRYな備忘録

Don't Repeat Yourself.

2013-11-27から1日間の記事一覧

memo: TypeScriptの継承と型

memo module Sample { export class MyBase1 { constructor(public name: string, public age: number){} greet(): MyBase1 { return this; }//これを宣言しておかないと型通らない #0 ask(){}//これを宣言しておかないとメソッドが無いと言われる #1 } expo…