Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

version 9.0.0 Cannot read property 'kind' of undefined #140

Open
daustany opened this issue Feb 11, 2020 · 3 comments
Open

version 9.0.0 Cannot read property 'kind' of undefined #140

daustany opened this issue Feb 11, 2020 · 3 comments
Labels

Comments

@daustany
Copy link

I'm recently upgrade to version 9.0.0 but when doing production build I get below error:
after some researching I found some suggestion about installing IVY, but I'm trying do get success build without installing third-party.

ERROR in ./node_modules/ngx-dropzone-wrapper/fesm5/ngx-dropzone-wrapper.js
Module build failed (from ./node_modules/@angular-devkit/build-optimizer/src/build-optimizer/webpack-loader.js):
TypeError: Cannot read property 'kind' of undefined
    at isAngularDecoratorMetadataExpression (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:230:35)
    at checkNodeForDecorators (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:53:21)
    at visitNodes (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16631:30)
    at Object.forEachChild (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16857:24)
    at checkNodeForDecorators (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:44:31)
    at visitNode (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16622:24)
    at Object.forEachChild (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16752:21)
    at checkNodeForDecorators (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:44:31)
    at visitNode (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16622:24)
    at Object.forEachChild (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16809:24)
    at checkNodeForDecorators (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:44:31)
    at visitNode (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16622:24)
    at Object.forEachChild (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16820:24)
    at checkNodeForDecorators (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\src\transforms\scrub-file.js:44:31)
    at visitNode (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16622:24)
    at Object.forEachChild (D:\Developing\NETCore\Dobarg\angular\node_modules\@angular-devkit\build-optimizer\node_modules\typescript\lib\typescript.js:16716:21)
@carrilhoandre
Copy link

Any update? i have the same error

@daustany
Copy link
Author

Actually this version of ngx-dropzone-wrapper upgraded to Angular 9 as its version.
So, in Angular 9, a compiler newly added named IVY.
You have two option, upgrade whole your project to Angular 9 or use ngx-dropzone-wrapper older version.

To upgrade your project to Angular 9 use this link:
https://www.techiediaries.com/angular/upgrade-angular-8-7-to-angular-9-with-cli-ng-update/

And to use "ngx-dropzone-wrapper" older version (8) use:
https://www.npmjs.com/package/ngx-dropzone-wrapper/v/8.0.0

@carrilhoandre
Copy link

I dont know if update angular is a good idea. I have a large project and the incompatibility risk is high. I solved the problem updating the @angular-devkit/build-angular in packages.json

"devDependencies": {
"@angular-devkit/build-angular": "~0.803.20"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants