Closed noxi515 closed 4 years ago
I think this happens because of processing done in Angular CLI, so I am transferring it there.
So the error is thrown because the decorators
array is 1-based rather than 0-based. And we are iterating down to the zeroth term in the array.
See this screenshot...
This looks like it may be an issue with the reflect-metadata
package. By including the package, the behavior of the TypeScript helper __decorate
changes to use the Reflect.decorate
function provided by reflect-metadata
. As shown above, the Reflect.decorate
function does not guard against undefined decorators. The __decorate
helper, however, does provide a guard for such an occurrence when Reflect.decorate
is not present (code).
Does the application or any of its dependencies directly use the reflect metadata functionality? Angular applications built with the CLI have not required a reflect metadata polyfill (core-js was used) since version 8.0.4. Before that version it was only required for JIT builds.
Also reflect-metadata
is listed as deprecated: https://angular.io/guide/deprecations#reflect-metadata.
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.
🐞 bug report
Affected Package
not sure.
Is this a regression?
Yes. Angular8 and Angular9 (ivy disabled) works well.
Description
Using both
@grapecity/wijmo.angular2.all
library andimport-metadata
causes TypeError on bootstrap.🔬 Minimal Reproduction
ng new
to generate new project.npm i -P @grapecity/wijmo.angular2.all
to install library.WjGridModule
to AppModule, and edit app.component.html.import 'reflect-metadata'
in main.tshttps://github.com/noxi515/angular-wijmo-reflect-issue
🔥 Exception or Error
🌍 Your Environment
Angular Version: