Skip to content

Instantly share code, notes, and snippets.

@DevEarley
Last active February 20, 2019 04:06
Show Gist options
  • Save DevEarley/3fe7ee8dcbe1e9dab66496e719d169d8 to your computer and use it in GitHub Desktop.
Save DevEarley/3fe7ee8dcbe1e9dab66496e719d169d8 to your computer and use it in GitHub Desktop.
Handful of commands for creating angular apps. Now with Yarn!

This doc is using Angular 7 with Angular CLI.

Install Angular CLI

npm i -g @angular/cli@latest

Set Angular to use Yarn

ng config -g cli.packageManager yarn

Setup new project

ng new SomeApp --routing --skip-tests --minimal --style=scss --skip-git

(should use --createApplication=false) - https://blog.angularindepth.com/angular-workspace-no-application-for-you-4b451afcc2ba

OLD WAY = Angular 6 and NPM ========================================================

Create a project with inline styles and it will automatically create a routing module.

ng new project-name --routing --skip-tests --inline-style --style=scss

Create a component without creating it's own directory.

ng g c component-name --flat --inline-style

Install angular

npm i -g @angular/cli

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment