Untitled
unknown
plain_text
a year ago
674 B
2
Indexable
Never
class User { username: string; constructor(username: string) { this.username = username; } } class Admin extends User { isSuperAdmin: boolean; constructor(username: string, isSuperAdmin: boolean) { super(username); this.isSuperAdmin = isSuperAdmin; } } const user1: User = new User('user1'); // OK const user2: User = new Admin('admin1', true); // class ClickstreamId extends String { value: string; constructor(value: string) { super(value) this.value = value; } } const clickstreamIdObj = new ClickstreamId("someVale") const test: string = clickstreamIdObj