0
0
Angularframework~20 mins

Angular CLI installation and setup - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Angular CLI Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Angular CLI Installation Command
Which command correctly installs the Angular CLI globally using npm?
Anpm install --global angular-cli
Bnpm install @angular/cli -g
Cnpm global install angular-cli
Dnpm install -g @angular/cli
Attempts:
2 left
💡 Hint
The global flag is -g.
component_behavior
intermediate
2:00remaining
Angular CLI New Project Creation
What is the output behavior after running the command 'ng new my-app' in a terminal?
ACreates a new folder 'my-app' with Angular project files and installs dependencies
BOnly creates a folder 'my-app' without any files inside
CUpdates the existing Angular project in the current folder
DGenerates a new Angular component named 'my-app' inside the current project
Attempts:
2 left
💡 Hint
Think about what 'ng new' is designed to do.
📝 Syntax
advanced
2:00remaining
Correct Angular CLI Command to Serve Project
Which command correctly starts the Angular development server for the current project?
Ang build --serve
Bng serve
Cng run
Dng start
Attempts:
2 left
💡 Hint
The command to launch the dev server is short and simple.
🔧 Debug
advanced
2:00remaining
Error When Running 'ng' Command
You installed Angular CLI globally but running 'ng version' gives 'command not found'. What is the most likely cause?
AYou must run 'npm link @angular/cli' after installation
BAngular CLI was installed locally, not globally
CThe npm global bin folder is not in your system PATH environment variable
DYou need to restart your terminal after installation
Attempts:
2 left
💡 Hint
Check if your system knows where to find global npm commands.
lifecycle
expert
2:00remaining
Angular CLI Version Compatibility
You have Angular CLI version 15 installed globally but your project uses Angular version 13. What is the expected behavior when running 'ng serve' inside the project folder?
AThe CLI will warn about version mismatch but still serve the project
BThe CLI will refuse to run and throw an error about incompatible versions
CThe CLI will automatically downgrade itself to version 13
DThe CLI will serve the project but with missing features from version 15
Attempts:
2 left
💡 Hint
Angular CLI tries to work with older projects but warns you.