Skip to content

Cannot generate ng2 with ng new #5648

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

Closed
jderus opened this issue Mar 25, 2017 · 5 comments
Closed

Cannot generate ng2 with ng new #5648

jderus opened this issue Mar 25, 2017 · 5 comments

Comments

@jderus
Copy link

jderus commented Mar 25, 2017

Bug Report or Feature Request (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request

Versions.

@angular/cli: 1.0.0
node: 7.4.0
os: win32 x64

Repro steps.

Cannot generate ng2 project with ng new.
Existing documentation and help is misleading and inconsistent.

EG:

  1. Changelog says that ng new has default of ng4. Does not show how to override that default.
  2. wiki shows that --ng4 default value is set to false. Conflict with Typescript Broccoli Plugin doesn't pass error message to broccoli #1 and isn't correct. Explicitly invoking this option with ng new does not generate a ng2 project
    See: https://github.com/angular/angular-cli/wiki/new
  3. ng new -- help does not reference the option --ng4 nor specify how to override the default of ng4 generation.

Desired functionality.

If ng-cli's ng new command will continue to support ng2 generation, please document how to do so, and make the documentation consistent. If not, fix up the docs.

Mention any other details that might be useful.

@dave11mj
Copy link
Contributor

Hi @jderus !

This is actually a duplicate of #5615 . You can read more about why ng2 is no longer supported on the comments of that issue. ^^

@hansl
Copy link
Contributor

hansl commented Mar 25, 2017

Closing this by the above comment.

@hansl hansl closed this as completed Mar 25, 2017
@jderus
Copy link
Author

jderus commented Mar 25, 2017

Gotcha, thanks!
I completely understand it is a nit, but what about the misleading links I supplied?

EG https://github.com/angular/angular-cli/wiki/new

ng4
`--ng4` _default value: false_

Create a project with Angular 4 in the template.

Plus: https://github.com/angular/angular-cli/blob/master/CHANGELOG.md

By default, now that Angular 4 is final, we will generate an Angular 4.0 project with ng new.

This kinda gives the impression that ng2 generation is supported by the cli with ng new command.
Recommendation is to remove --ng4 from the wiki and clarify the changelog to state a more verbose version like your resolutions:

The cli no longer supports creating new projects with ng2 since ng4 is out. You can still manually fall back to Angular module versions in package.json after ng new.

@dave11mj
Copy link
Contributor

I kinda agree with your suggestion @jderus that they wiki and maybe changelog could be a bit more explicit since I myself at first thought I could opt-in on ng2 ~

@angular-automatic-lock-bot
Copy link

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.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants