Top "Angular-directive" questions

At a high level, directives are markers on a DOM element (such as an attribute, element name, comment or CSS class) that tells the Angular 2+ framework to attach a specified behavior to that DOM element or even transform the DOM element and its children.

How to pass Object to NgStyle directive in Angular 2?

I'm trying to use NgStyle directive with an object variable like so: @Component({ template: ` <div [ngStyle]="object"> some …

angular angular-directive
Angular Test Error - NullInjectorError: No provider for TrimInputDirective

I created an Angular Directive, that uses CSS selectors to automatically trim inputs in my application, it looks like so... …

javascript angular unit-testing angular-directive angular-unit-test
Angular 4 Confirm Directive

I'm trying to create a directive for jQuery Confirm in Angular 4. However, I'm having a hard time stopping binded events …

angular angular-directive jquery-confirm
ng-repeat sorting arrow not working in javascript datatables

I'm very new to AngularJs and datatables. I have a requirement to populate the data in table rows using ng-repeat. …

jquery angularjs html datatables angular-directive
Angular component won't display

I have piece of html I want to show as a component, as I'm not manipulating the DOM. As a …

javascript angularjs web-component angular-directive angular-components
How to set HTML content in the ElementRef (nativeEelement)?

I want to set the content of HTML element with directive. export class AdvertisementDirective { constructor(el: ElementRef) { el.nativeElement.style.…

angular angular-directive
Difference between ngStorage and $window.localStorage

What is the difference between ngStorage and $window.localStorage? When is it better to use one instead that the other? …

javascript angularjs local-storage angular-directive ng-storage
What is the calling order of angularjs functions (config/run/controller)?

There are controllers constants directives services factory run config filters functions of angular.js. What is the calling order of …

javascript angularjs angular-directive angular-services angular-module