how to create an element and add a class to it javascript dom code example
Example: js create element with class
var element =document.createElement("span");
element.className = "aClassName";
var element =document.createElement("span");
element.className = "aClassName";