inherit class constructor function from parent class - fixes babel-plugins/babel-plugin-flow-comments#15
This commit is contained in:
parent
e51949e402
commit
e15a28cc1c
@ -226,7 +226,9 @@ export default class ClassTransformer {
|
||||
*/
|
||||
|
||||
buildConstructor() {
|
||||
return t.functionDeclaration(this.classRef, [], this.constructorBody);
|
||||
var func = t.functionDeclaration(this.classRef, [], this.constructorBody);
|
||||
t.inherits(func, this.node);
|
||||
return func;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user