Rocket.Chat.Apps-cli icon indicating copy to clipboard operation
Rocket.Chat.Apps-cli copied to clipboard

Class hierarchy causes unexpected Typescript error

Open GJKrupa opened this issue 4 years ago • 5 comments

In my app I've included a class hierarchy with a base and a derived class in the same directory (./src). If I attempt to instantiate an instance of the derived class I see the following error when packaging the app:

❯ rc-apps package
packaging your app... !
    TypeError: Class extends value undefined is not a constructor or null

The code is valid and compiles if I use npx tsc.

See https://github.com/GJKrupa/rocketchat-cli-125 for an example

If I remove the call to the derived class constructor or remove the class hierarchy then the error goes away

GJKrupa avatar Oct 15 '21 14:10 GJKrupa

This appears to be a recent regression since the app compiles successfully with version 1.9.0 of the CLI.

GJKrupa avatar Oct 15 '21 14:10 GJKrupa

+1 on version 1.10.1

OrigamiKill avatar Oct 26 '21 14:10 OrigamiKill

I can confirm this bug and the workaround related to 1.9.0.

Thank you, @GJKrupa

kirillk77 avatar Nov 19 '21 05:11 kirillk77

@d-gubert hey, Douglas! Can you take a look at that issue?

ankar84 avatar Nov 19 '21 05:11 ankar84

Hey, guys. This is still a problem..

eonae avatar Sep 24 '24 22:09 eonae