Question · Angular course · Module 13: UI and Styling
The :host-context selector
What is the :host-context(.dark-theme) selector used for in a component's styles?
Answer options
- It styles the component depending on an ancestor's class in the DOM tree
- It creates a new Shadow DOM context
- It hides the component in dark mode
- It imports a context from another component
You can check the correct answer by solving this task in the CodeWorlds game.