Answers for "angular add conditional attributes"

1

What is the best way to conditionally apply attributes in AngularJS?

<div contenteditable="{{ condition ? 'true' : 'false'}}"></div>
Posted by: Guest on August-02-2021
0

angular add html attribute on condition

<input [attr.attribute] = "condition ? '' : null" />
Posted by: Guest on January-13-2021

Code answers related to "angular add conditional attributes"

Browse Popular Code Answers by Language