Custom styles that add/remove custom classes?
It's already possible with Classes section (you can remove/toggle/update them)
Read full answer below βQuestion
Currently, all the style manager values that you change for an element simply update a <style> tag inline in the HTML. Is it possible to change this behavior so that changing the CSS values adds or removes custom classes to the element?
A good reason for this is Bootstrap 4. 99% of Bootstrap customization involves simply adding classes to the element to alter various things like margins, padding, display values, etc.
Is it possible to do this? If not is this a valid feature request?
Answers (3)
It's already possible with Classes section (you can remove/toggle/update them)

Have you considered that the potential target audience for such a tool (think eCommerce merchandisers) has no idea what "classes" are in HTML and would be able to greatly benefit from having simple dropdown menus to choose from predefined settings?
Have you considered that the potential target audience for such a tool (think eCommerce merchandisers) has no idea what "classes" are in HTML and would be able to greatly benefit from having simple dropdown menus to choose from predefined settings? Yeah sure, indeed I've planned to make this part l...
Related Questions and Answers
Continue research with similar issue discussions.
Issue #661
Class attribute not removed
Hello ! I noticed a problem with style manager when we add/remove classes. When we remove all classes it doesn't remove then from the gener...
Issue #1746
[FEATURE REQUEST] Don't Strip off html , head and body tags from imported html
Hi Team, We have noticed grapesjs has customised the actual template uploaded, by stripping off the html, head and body tags and adds new s...
Issue #908
[FEATURE REQUEST] Add custom classes to panels and other editor elements
When using a UI framework that provides custom classes, it would be nice to be able to use these classes on things like panels, so you woul...
Issue #843
[QUESTION] - CssComposer - removes unused classes
hi @artf , I import a html , using import from grapesjs-preset-newsletter, with some css classes inside the <style> tag. After the import,...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins βPremium plugins ship with support, regular updates, and production-ready features β save days of integration work.
Browse premium plugins βRelated tutorials
In-depth guides on the same topic.
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.