x)
- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [x] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
This used to work with Angular CLI v8.0
Trying to use Angular Universal.
The add command:
ng add @nguniversal/express-engine --clientProject my-project
simply failed to create the file app.server.module.ts with the message:
Cannot read property 'kind' of undefined
ng add @nguniversal/express-engine --clientProject my-project
The command above terminated with this message:
Installed packages for tooling via npm.
Cannot read property 'kind' of undefined
Angular CLI: 8.3.3
Node: 10.16.0
OS: win32 x64
Angular: 8.2.5
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router
Package Version
-----------------------------------------------------------
@angular-devkit/architect 0.801.3
@angular-devkit/build-angular 0.801.3
@angular-devkit/build-optimizer 0.801.3
@angular-devkit/build-webpack 0.801.3
@angular-devkit/core 8.1.3
@angular-devkit/schematics 8.3.3
@angular/cdk 8.2.0
@angular/cli 8.3.3
@angular/flex-layout 8.0.0-beta.27
@angular/material 8.2.0
@ngtools/webpack 8.1.3
@nguniversal/express-engine 8.1.1
@schematics/angular 8.3.3
@schematics/update 0.803.3
rxjs 6.5.3
typescript 3.4.5
webpack 4.35.2
Hi @nnworkspace, would you be able to share a reproduction? I tried this on a newly generated project but I was unable to replicate it.
Installed packages for tooling via npm.
CREATE src/main.server.ts (361 bytes)
CREATE src/app/app.server.module.ts (427 bytes)
CREATE tsconfig.server.json (273 bytes)
CREATE webpack.server.config.js (1466 bytes)
CREATE server.ts (1980 bytes)
UPDATE package.json (1857 bytes)
UPDATE angular.json (4385 bytes)
UPDATE src/main.ts (432 bytes)
UPDATE src/app/app.module.ts (359 bytes)
added 30 packages from 28 contributors and audited 20975 packages in 6.991s
found 0 vulnerabilities
audited 20975 packages in 5.82s
found 0 vulnerabilities
Thanks
Hi Alan,
could you please try to run the add nguniversal/express-engine command on this project (packed in a zip file)? This failed with latest Angular-related packages on my machine. Thanks!
@alan-agius4
This error should be obsolete in version 9.
Can you try the below
ng add @nguniversal/express-engine@next --client-project=foo
Closing as this has been in the v9.0.0-next.1 of '@nguniversal/express-engine`.
Kindly note that issues related to @nguniversal packages should be created in their issue tracker https://github.com/angular/universal/issues
This error should be obsolete in version 9.
Can you try the below
ng add @nguniversal/express-engine@next --client-project=foo
Hi @alan-agius4
This worked for me very well, thank you very much!
nn
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._
Most helpful comment
This error should be obsolete in version 9.
Can you try the below