Angular CLI error Cannot read property 'write' of undefined

Angular CLI error Cannot read property 'write' of undefined

cannot read property 'entries' of undefined angular cli
typeerror cannot read property 'kind' of undefined in angular 7
cannot read property 'projecttype' of undefined
error cannot read property dasherize of undefined
typeerror cannot read property 'kind' of undefined graphql
cannot read property moduledobootstrap of undefined
typeerror: cannot read property ɵmod of undefined
typeerror: cannot read property 'externalmoduleindicator' of undefined

When I run my project by ng serve I see this error in command prompt

Cannot read property 'write' of undefined
TypeError: Cannot read property 'write' of undefined
    at UI.write (C:\Source\Front\node_modules\@angular\cli\ember-cli\lib\ui\index.js:56:23)
    at UI.writeLine (C:\Source\Front\node_modules\@angular\cli\ember-cli\lib\ui\index.js:69:8)
    at Class.run (C:\Source\Front\node_modules\@angular\cli\tasks\serve.js:237:12)
    at check_port_1.checkPort.then.port (C:\Source\Front\node_modules\@angular\cli\commands\serve.js:123:26)
    at process._tickCallback (internal/process/next_tick.js:68:7)

Since the update Angular CLI to the last version 6.1.1, this problem has arisen How can I solve this problem?

Package version:

Angular CLI: 6.1.1
Node: 10.7.0
OS: win32 x64
Angular:
...

Package                      Version
------------------------------------------------------
@angular-devkit/architect    0.7.1
@angular-devkit/core         0.7.1
@angular-devkit/schematics   0.7.1
@schematics/angular          0.7.1
@schematics/update           0.7.1
rxjs                         6.2.2
typescript                   2.7.2

related with angular-cli latest release - 6.1.0 and 6.1.1.downgrade angular-cli to 6.0.8 and it works fine.

Keep getting this error: Cannot read property 'kind' of undefined , I have encountered same issue and it got resolved when I executed command ng update. It happens as upgrading angular version also requires  It is happening mainly because with Latest Angular-cli and Angular 7, folder structure might be changed as the way of importing external files are only supported with Assets directory of Project Structure.


I can't reproduce your issue. You still have an old ember-cli folder in your error logs. This folder is not part of the AngularCLI anymore. So to update your project:

First update all of the global dependencies of your system:

npm update -g

Then update your local dependencies this way:

rmdir /S /Q node_modules
npm install --save-dev @angular/cli@latest
ng update --all
npm install

It will remove your old node_modules folder first and then it will reinstall it properly and cleanly.

Cannot read property 'entries' of undefined - Angular CLI, I tried the other suggestions here, but ended up removing and re-installing Node.​js and NPM. Finally did the trick for me. One thought on “ Angular cli build prod: TypeError: Cannot read property ‘kind’ of undefined ”


I was have the same problem and I found the solution at github issue related to the same problem

npm install --save-dev @angular/cli@6.1.1
ng update @angular/cli --migrate-only --from=1.7.4

Web cannot run after update angular cli to 6.1.0 #11661

Angular CLI error Cannot read property 'write' of undefined, When I run my project by ng serve I see this error in command prompt. Cannot read property 'write' of undefined TypeError: Cannot read  Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 8, 2019


Angular 7 CLI ng generate component error: 'Cannot read property , Angular 7 CLI ng generate component error: 'Cannot read property 'sourceRoot' of undefined' - angular. In this tutorial, we will see a most common error faced by the Angular developers named as "TypeError Cannot read property of undefined". So we will see how


Core.js:19865 ERROR TypeError: Cannot read property , Core.js:19865 ERROR TypeError: Cannot read property 'getDisplayMedia' of “​build”: “ng build --aot --prod --configuration=${environment}”, Hi, i just tried to migrate to Angular 9 and followed the Instruction. But getting this mistake:ERROR in Cannot read property 'length' of undefinedHere is my package


angular cli package failure on build (TypeError: Cannot read , angular cli package failure on build (TypeError: Cannot read property 'write' of undefined). Closed - Not a Bug Azure DevOps · avatar image  angular-cliでのエラー「Cannot read property 'AssetUrl' of undefined」 Angular2 angular-cli. More than 3 years have passed since last update.