Angular 10 NgPlural Directive
In this article, we are going to see what is NgPlural in Angular 10 and how to use it.
The NgPlural in Angular10 is used to Add or remove DOM sub-trees based on a numeric value.
NgModule: Module used by NgPlural is:
- Create an Angular app that to be used.
- There is no need for any import for the NgPlural to be used.
- Define a variable in app.component.ts
- In app.component.html use ngPlural with ngPlural case directive in the element with conditions to be checked..
- Serve the angular app using ng serve to see the output.