Modifying HTML Content and Attributes

What's the best practice for setting inline styles?
element.style.backgroundColor = 'red';
element.setAttribute('style', 'background-color: red;');
Next Question (19/20)