Loading

Quipoin Menu

Learn • Practice • Grow

Direction: Choose the correct option

Q1.

What does the command `ng generate component user` do?
A. Installs a package
B. Creates a new component named 'user'
C. Creates a new module named 'user'
D. Generates a service
Direction: Choose the correct option

Q2.

Which command builds the Angular project for production?
A. ng serve
B. ng build
C. ng compile
D. ng build --prod
Direction: Choose the correct option

Q3.

What does `ng serve --open` do?
A. Opens the project in editor
B. Opens the terminal
C. Serves the app and opens it in browser
D. Starts a debug session
Direction: Choose the correct option

Q4.

How do you generate a service using Angular CLI?
A. Both A and C
B. ng create service data
C. ng g s data
D. ng generate service data
Direction: Choose the correct option

Q5.

What is the purpose of `ng test` command?
A. Test configuration
B. Test production build
C. Run unit tests
D. Run end-to-end tests
Direction: Choose the correct option

Q6.

What does `ng e2e` command do?
A. Runs end-to-end tests
B. Deploys the app
C. Runs unit tests
D. Builds the app
Direction: Choose the correct option

Q7.

How do you generate a pipe using Angular CLI?
A. Both A and B
B. ng generate pipe my-pipe
C. ng g p my-pipe
D. ng create pipe
Direction: Choose the correct option

Q8.

What is the purpose of `ng lint` command?
A. Lints the code according to configured rules
B. Adds linting
C. Creates lint files
D. Removes lint
Direction: Choose the correct option

Q9.

How do you generate a module with routing?
A. ng create module admin --routing
B. ng g m admin --routing
C. ng generate module admin --routing
D. ng new module admin --routing
Direction: Choose the correct option

Q10.

What does `ng update` do?
A. Updates the project
B. Updates the CLI
C. Updates Angular dependencies to newer versions
D. Updates Node.js