Closed dfenerski closed 2 years ago
@dfenerski I haven't checked in detail, but right now I think you are right: because of the constructor signature the interface should also be generated when a class does not add anything to the interface. I'll check as soon as UI5con stress allows.
@dfenerski on second glance, what exactly is not working or missing?
When I e.g. use the app in the "custom-controls" branch of the hello word app and add another control which inherits from MyControl
but does not specify any new properties etc., then its constructor works perfectly fine as far as I see. It just inherits the one from the parent class, as expected.
For reference: the code where such classes are ignored is here. In fact there is already a "FIXME" about exactly this topic, but right now it looks like this can just be removed.
@akudev you are right, it is working fine. I got confused because only generated props need an additional interface; instance methods do not due to standard import
/ export
statements during devtime. Thanks for the responsiveness!
Consider the following class:
The generator completely skips it, and when imported typescript remains blind for the constructor signatures.
Is this planned, should I add mock props, or maybe manually write declaration to be merged?