ngx-ui-switch
ngx-ui-switch copied to clipboard
Use of multiple switch elements gives duplicate id warning in console
<ui-switch [id]="module.id" [name]="module.id" [ngModel]="module.is_selected"> </ui-switch>
I am using above element in a loop, I am getting warning in console regarding duplicate id. As by default ui-switch element adds id with value 'enabled' and its static we cannot bind it.
I want a way to bind id attribute using [id]="module.id"
Thanks in advance !
does attr.id
work or do you need to bind it to an element inside of the switch?
does
attr.id
work or do you need to bind it to an element inside of the switch?
@ravtoleakshay Any update? Will close otherwise
@cmckni3 Facing same issue. this issue causes WCAG errors. [attr.id]="some-id" does not work.