Standalone components declare imports directly—no NgModule required for new apps.
Important interview questions and answers
- Q: Why does this matter?
A: Standalone components declare imports directly—no NgModule required for new apps.
Self-check
- Summarize Standalone components in one sentence.
- What would you try next in the playground?
Challenge
Standalone components hands-on
- Edit the default code.
- Click Run in browser.
- Confirm preview or terminal output.
Done when: preview or terminal matches the lesson goal.
Tip: Set standalone: true and list imports on the component—no NgModule wrapper needed in new Angular apps.
Interview prep
- What is a standalone component?
A component with
standalone: truethat declares its ownimportsinstead of belonging to an NgModule.