Which decorator is used to define a custom directive in Angular?
- @Component
- @Directive
- @Injectable
- @NgModule
To define a custom directive in Angular, you use the @Directive decorator.
Loading...
Related Quiz
- The router-outlet directive acts as a _____ where the routed component is displayed.
- What is the primary purpose of using a Route Resolver in Angular?
- You need to test an Angular service that makes HTTP requests to an API. You want to ensure your tests are isolated and do not actually make HTTP calls. What approach would you take?
- How can you access a specific form control within a form group in Angular?
- To set up the testing environment before running any test suite in Protractor, you can utilize the _____ function in the configuration file.