摘要:
###接口标识符 interface Swim { swimming: () => void } //作为标识符 const a: Swim = { swimming() { return 'sss' } } console.log(a); ###类实现接口 interface Swim { swi 阅读全文
posted @ 2022-01-03 16:49
最爱宋人头
阅读(44)
评论(0)
推荐(0)
摘要:
###继承 class Person { name: string; constructor(name: string) { this.name = name; } } class Student extends Person { constructor(name: string) { super( 阅读全文
posted @ 2022-01-03 10:27
最爱宋人头
阅读(31)
评论(0)
推荐(0)