You cannot directly update CSS classes in a separate css file using jQuery. However, you can create the <style> and add / overwrite the CSS class:
$('<style>.newClass { color: red; }</style>').appendTo('body');
When updating the CSS class, you need to take care of the cascading order . Otherwise, perhaps this will not be a consequence of the effect.
William Niu
source share