addstyle - dingojs/dingo.js GitHub Wiki
addstyle(id,args);
id(string)- the id of the element
args(arr)- an associative array of properties and their values to add to an element type or a class.
A style works exactly how css works. If there is a '.' before the name in the id, it will create a class. If not, it will reference an html tag:
addstyle('.test',{color:'blue'});//creates a css class called .test that sets the text color of all elements with that class
addstyle('h1',{'background-color':'red');//sets the color of all <h1> tags
addelem('test','h1',{innerHTML:'Hello World!',className:'test');//renders blue with red background