Cañete,Brandon L.git-fundamentals-documentation.hashnode.dev·Sep 27, 2024Angular DirectivesIn this article we will tackle what Angular Directives, their types, use cases and examples. What is Angular Directives? Directives are classes that add additional behavior to elements in your Angular Applications. Built-in Angular Directives is us...Angular
Thirdy Gayaressoftware-engineer.thirdygayares.com·Jun 3, 2024Understanding Angular: Components, Routing, and Directives ExplainedComponents Components are the building blocks of Angular apps. Each component has: Template: The HTML part of the component. Class: Contains the logic (written in TypeScript). Styles: Defines the look of the component @Injectable({ providedIn...AngularAngular
Gagan BNgagan-bn.hashnode.dev·Mar 19, 2024Angular's DirectiveUnderstanding Angular Directives In Angular, directives are essential tools for adding extra functionality to elements. They are implemented using the @Directive decorator. For instance, Angular provides built-in directives like ngIf for conditionall...Angular
Arpita Priyadarshini Sahoosahoo.hashnode.dev·Mar 17, 2024Show Truncated tooltip in <@angular/>In UI development we come across such things like not to show tooltip/title when the text is completely showing. We can solve this problem by assigning classes to each text content and that would be so much hectic. In angular we use Directive for sol...89 readstext truncate in angular
brian treesebriantreese.hashnode.dev·Sep 1, 20234 Ways to Dynamically Add Classes in AngularHey there, have you ever needed to programmatically add a class to an element in an Angular application? Like, maybe when a button is disabled, we need a class, but then once it’s enabled, we don’t. Or how about when a form goes from an invalid state...angular classes
Dany Paredesdanywalls.com·Apr 13, 2023How to get and use ng-template, ng-container and ng-contentWhen I started to play with templates and dynamic content in angular, I get surprised by multiple directives in angular to work with it ng-template, ng-container, and ng-content. Each one is pretty similar initially; each has exceptional use cases an...4 likes·8.4K readsAngularAngular
Gassai Hamzapotatoes.hashnode.dev·Jan 17, 2023How I created a directive in Angular that renders components only if user is authorized?Recently, I was working on an Angular project where certain components were public meaning that everyone should see them and others should be rendered only if the user is authenticated or have a specific role, so I was doing something like this: <!--...4 likes·193 readsAngular