Issue
const rootElem = view.rootNodes[0]; if (rootElem) { this.renderer.removeClass(rootElem, 'disabled'); }
Here am getting that Cannot read properties of undefined (reading 'remove') in the promise, what am i missing ?
Solution
am calling that remove calss as <ng-container *appPermissions="'SOME_KEY'; group: ''"></ng-container>
inside appPermissions directive i have removeClass, as <ng-container>
doesn't have any class and we can't add or remove class on that tag so <div *appPermissions="'SOME_KEY'; group: ''"></div>
calling my directive in a div resolves the issue.
Answered By - Govardhan
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.