What command aliases do you use when using Angular CLI?
Experience Level: Junior
Tags: AngularAngular CLI
Answer
The following are the most used command aliases:
- ng v = ng version (outputs Angular CLI version)
- ng s = ng serve (builds and serves your application)
- ng b = ng build (compiles an Angular application)
- ng g = ng generate (generates files - component, module, class, ...)
- ng l = ng lint (runs linting tools)
- ng t = ng test (runs unit tests in a project)
- ng n = ng new (creates a new Angular application)
- ng e = ng e2e (builds, serves, runs e2e tests)
Related Angular CLI job interview questions
What does -g parameter do when you are installing npm package using npm install command?
Angular CLI JuniorWhy should I use Angular CLI?
Angular CLI JuniorHow do you build your Angular application using Angular CLI for use on production environment?
AngularAngular CLI JuniorHow do you build your Angular application using Angular CLI for use on a local or development environment?
AngularAngular CLI JuniorUsing Anular CLI, how do you create a new component that will be automatically imported to your feature module that is called feature-module1?
AngularAngular CLI Junior