add styles with javascript code example
Example 1: add css in javascript
document.getElementById("demo").style.display = "none";
Example 2: how to change css using javascript
document.getElementById("myText").className = "anyNewClass"
document.getElementById("demo").style.display = "none";
document.getElementById("myText").className = "anyNewClass"