addStyle

adds a CSS rule to the page

void addStyle(string css, [string group_name] );
cssstringthe CSS text
group_namestringoptional, the name of the CSS group

Example

webix.html.addStyle(".myclass{ color:red; }");

Details

All styles added by the addStyle() method are remembered in Webix html helper in groups. The group name can be specified as the second parameter. If no group name is specified, the style will be saved as a part of the "default" group.

The group_name parameter makes sense if you want to remove the added CSS rules afterwards.

See also
Back to top