Angular CLI project creation

Hi experts,

I'm did the basic angular example at this link.
https://angular.io/guide/quickstart

So I installed node 8.9.3  and npm.

In my windows 10 command prompt after i installed node and npm...

if I type the following
>node --version

I get this: v8.9.3

if I type the following
>npm --version

I get this 5.5.1

So then using angular cli I created the angular example from the link above.

After I created the example in the link above, my directory looks like this:

Capture.PNG
So when I serve the project using this command

>ng serve --open

The app runs fine and looks like this when the browser launches

app run

After I ran the app, then in the command prompt I typed in this command to see the angular CLI version:

> ng --version

When I run that command I get this:

version

So I'm assuming the sample project I just created above is an Angular 5.1.2 project.

When creating the project with Angular CLI,
is there a command that lets you input whether you want to create an Angular 2 project or Angular 4 project or Angular 5 project?
LVL 1
maqskywalkerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Julian HansenCommented:
Question: Why do you want to create an Angular 2 or Angular 4 project? They are essentially the same - the differences are in how the app is compiled and packaged (bar a few minor enhancements to the Angular syntax)

If you want to build against Angular 4 you can always go into your package.json and specify a different angular package - but the question is why would you want to?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
maqskywalkerAuthor Commented:
Thanks. For the info. It's not that I want to. Just wondering of the capabilities of Angular CLI.
I will stick with the latest version of Angular.
0
Julian HansenCommented:
You can do it - I have several Angular 4 projects that I maintain with CLI - it gives me a warning when I compile it about the version of Angular being out of date with the global version but it compiles and runs.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Node.js

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.