interface person {
sex: string;
}
interface stu {
name: string;
order?: number;
new (p: person): any;
}
class Test implements stu {
name: string = "joyKit";
order?: number = 1;
}
export function test() {
const t = new Test();
}
interface person {
sex: string;
}
interface stu {
name: string;
order?: number;
new (p: person): any;
}
class Test implements stu {
name: string = "joyKit";
order?: number = 1;
}
export function test() {
const t = new Test();
}
这样不行吗