javascript classlist add

JavaScript
 document.getElementById("myDIV").classList.add("mystyle"); 
Source

Also in JavaScript: