class A {
public x;
constructor(x: number) {
this.x =x
}
Foo(){
}
}
class B extends A {
constructor(){
super(7)
}
Boo(){
}
}
Last active
September 23, 2021 08:32
-
-
Save nom3ad/26473caae0144ac691353b2a7f9f35eb to your computer and use it in GitHub Desktop.
ts-playground
type Constructor = new (...args: any[]) => unknown;
function ComposeClassWithMixins<B extends Constructor, M extends Constructor[]>(base: B, ...mixins: M): any {
return class MixedClass extends (b...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment