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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide a shorthand for starting Angular 2 apps #1595

Closed
tjvantoll opened this issue Mar 10, 2016 · 8 comments
Closed

Provide a shorthand for starting Angular 2 apps #1595

tjvantoll opened this issue Mar 10, 2016 · 8 comments
Assignees
Milestone

Comments

@tjvantoll
Copy link
Contributor

Related to #1498.

As we talk about Angular 2 more I think it’s important that we optimize the getting started experience as much as possible. With that in mind I’d like to propose that we create a --ng flag for tns create that acts as a shorthand for tns create my-app-name --template https://github.com/NativeScript/template-hello-world-ng.

So tns create my-next-great-angular-project --ng. Thoughts?

@rosen-vladimirov
Copy link
Contributor

@tjvantoll Is it expected to have tns-core-modules from angular tag?
Also we may add a shortcut for the template, as we've created for typescript:

tns create my-next-great-angular-project --template ng
tns create my-next-great-angular-project --template angular

Both will use the angular template.

In case we provide --ng option, I believe the new app should install modules from angular tag, but maybe I'm not correct.

@ligaz
Copy link

ligaz commented Mar 11, 2016

@hdeshev Do we plan to maintain the @angular tag in the long term?

@hdeshev
Copy link
Contributor

hdeshev commented Mar 11, 2016

We need @angular for out of band releases, so that we can release the angular renderer with unofficial tns-core-modules features/fixes. I expect that need to diminish greatly over the next couple of months, and I hope it is temporary.

I don't expect it to disappear completely, but we'll probably use it very rarely. I think it's perfectly fine to pick a version of nativescript-angular that works with the official tns-core-modules release and use that when starting a project with the --ng option. (Actually picking the right version is a thing we need to agree upon too 😉)

@tjvantoll
Copy link
Contributor Author

@rosen-vladimirov I would expect tns create my-next-great-project --ng to simply clone https://github.com/NativeScript/template-hello-world-ng. If that template needs a special version of tns-core-modules its package.json can just take care of that for me.

I like the idea of having tns create my-next-great-angular-project --template ng, but personally I’m in favor of (additionally?) having tns create my-next-great-angular-project --ng as a even shorter shorthand 😄

@rosen-vladimirov
Copy link
Contributor

@tjvantoll I agree we can have both options ;)

@NathanWalker
Copy link
Contributor

love this. 👍

@vchimev
Copy link

vchimev commented Mar 24, 2016

With the shorthand implementation of:

tns create my-next-great-angular-project --template angular

and

tns create my-next-great-angular-project --ng

I think it makes sense to support also

tns create my-next-great-typescript-project --tsc

for

tns create my-next-great-typescript-project --template typescript

This will keep the command options consistent as well.

What do you think?

@vchimev
Copy link

vchimev commented Mar 28, 2016

Moved my suggestion to a separate issue: #1650.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants