insidewhy/queueing-subject

TypeError in constructor of QueueingSubject

Closed this issue · 7 comments

When choosing es2015 as target language in our Angular 8 Typescript project we get the following runtime error with version 0.3.0:

ERROR Error: Uncaught (in promise): TypeError: Class constructor Subject cannot be invoked without 'new'
TypeError: Class constructor Subject cannot be invoked without 'new'
    at new QueueingSubject (index.js:17)

Inlining the code of the class QueueingSubject seems to be working, but using the npm package does not.

QueueingSubject doesn't have a constructor... or at least not an explicitly defined one. Hm, weird.

@eweap Thanks so much for the solution to this issue.

Released version 0.3.1 with the fix.

@eweap Excellent work! I can confirm the es2015 version is working correctly.

However, I had to manually build and install the es2015 as the newly released version 0.3.1 in node_modules/queueing-subject contains just the source code? @ohjames

@jippeholwerda Oops, I'd forgot to add a prepublish script to do the build and had not anticipated such stupidity when I did the publish. Published 0.3.2 with the full build. Sorry for my incompetency ;)

@jippeholwerda And also thanks for alerting me (and putting up with me :P)

@ohjames Much better now. Thanks for your quick actions!