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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Angular universal schematic broken on v7.3.5 #13896

Closed
Fattouh92 opened this Issue Mar 13, 2019 · 7 comments

Comments

Projects
None yet
3 participants
@Fattouh92
Copy link

Fattouh92 commented Mar 13, 2019

馃悶 Bug report

Command (mark with an x)

- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [X] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Is this a regression?

I see it working in 7.2.4

Description

A clear and concise description of the problem...

Running ng add @nguniversal/express-engine --clientProject [existingProjectName] only installs @nguniversal/express-engine@7.1.1 and does not create or change files

馃敩 Minimal Reproduction

Update to cli v7.3.5
run ng new new-project
run ng add @nguniversal/express-engine --clientProject new-project

馃敟 Exception or Error





馃實 Your Environment




Angular CLI: 7.3.5
Node: 8.12.0
OS: darwin x64
Angular: 7.2.9
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.13.5
@angular-devkit/build-angular     0.11.4
@angular-devkit/build-optimizer   0.11.4
@angular-devkit/build-webpack     0.11.4
@angular-devkit/core              7.3.5
@angular-devkit/schematics        7.3.5
@angular/cli                      7.3.5
@ngtools/webpack                  7.1.4
@schematics/angular               7.3.5
@schematics/update                0.13.5
rxjs                              6.4.0
typescript                        3.1.6
webpack                           4.23.1

Anything else relevant?

@alan-agius4

This comment has been minimized.

Copy link
Collaborator

alan-agius4 commented Mar 13, 2019

@Fattouh92, before running ng add are you changing the directory to new-project
ie: cd new-project?

I am unable to reproduction the issue from my end.

ng add @nguniversal/express-engine --clientProject new-project
Installing packages for tooling via npm.
npm WARN @nguniversal/express-engine@7.1.1 requires a peer of @angular/platform-server@^7.1.4 but none is installed. You must install peer dependencies yourself.

+ @nguniversal/express-engine@7.1.1
added 1 package and audited 42610 packages in 12.628s
found 0 vulnerabilities

Installed packages for tooling via npm.
CREATE src/main.server.ts (220 bytes)
CREATE src/app/app.server.module.ts (427 bytes)
CREATE src/tsconfig.server.json (219 bytes)
CREATE webpack.server.config.js (1360 bytes)
CREATE server.ts (1472 bytes)
UPDATE package.json (1874 bytes)
UPDATE angular.json (4411 bytes)
UPDATE src/main.ts (432 bytes)
@Fattouh92

This comment has been minimized.

Copy link
Author

Fattouh92 commented Mar 13, 2019

Yes I am changing to the directory, my bad I left it out

@alan-agius4

This comment has been minimized.

Copy link
Collaborator

alan-agius4 commented Mar 13, 2019

Can you share the complete output of the console?

@Fattouh92

This comment has been minimized.

Copy link
Author

Fattouh92 commented Mar 13, 2019

$ ng add @nguniversal/express-engine --clientProject web-client
Installing packages for tooling via npm.
npm WARN @smec/ng-commons@0.4.0 requires a peer of ngx-toastr@^8.10.0 but none is installed. You must install peer dependencies yourself.
npm WARN bootstrap@4.3.1 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself.
npm WARN bootstrap@4.3.1 requires a peer of popper.js@^1.14.7 but none is installed. You must install peer dependencies yourself.
npm WARN karma-jasmine-html-reporter@1.4.0 requires a peer of jasmine-core@>=3.3 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-ellipsis@1.1.3 requires a peer of @angular/common@^6.0.0-rc.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-ellipsis@1.1.3 requires a peer of @angular/core@^6.0.0-rc.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @nguniversal/express-engine@7.1.1 requires a peer of @angular/platform-server@^7.1.4 but none is installed. You must install peer dependencies yourself.

+ @nguniversal/express-engine@7.1.1
added 1 package and audited 42491 packages in 8.521s
found 3 vulnerabilities (1 low, 2 high)
  run `npm audit fix` to fix them, or `npm audit` for details
Installed packages for tooling via npm.
@alan-agius4

This comment has been minimized.

Copy link
Collaborator

alan-agius4 commented Mar 14, 2019

Hi, I looked into this and I am still unable to replicate this issue on a newly generated project.
Unfortunately, if no one is able to replicate this and provide some further info we'll be unable to address this.

@matheo

This comment has been minimized.

Copy link

matheo commented Mar 16, 2019

I was able to use the ng g universal schematic with the latest package versions, but now I don't know how to complete the server configuration in the angular.json to get the whole site built, currently, I'm just getting the main.js in the output (I'm evidently quite new to SSR, and I was expecting to get a static copy of my Angular App, sorry)

@alan-agius4

This comment has been minimized.

Copy link
Collaborator

alan-agius4 commented Mar 19, 2019

Hi @matheo, I suggest to redirect support requests to StackOverflow using tag angular-cli or gitter.

If you are wondering why we don't resolve support issues via the issue tracker, please check out this explanation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can鈥檛 perform that action at this time.