CSS Gets deleted
@RiyaThete to load css into editor, you need to insert it on grapesjs init, something like that: Or if you want to include css inline:
Read full answer below ↓Question
I have a website with multiple web pages (results-page, category page, home page) and a common css file for all pages (all.css).Within this css file : webpage (classes used) Home page ( class A, class B , class C) Results Page ( class B, class X, class Y ) Category page ( class R, class S , class X) When I load results-page in grape.js' editor using import plugin, I copy the entire all.css file and place it at the top of results Page in <style> tag. Without making any changes I exported the zip using export plugin and I noticed that the css file within zip has only following classes : A,B,X,Y...
Answers (3)
@RiyaThete to load css into editor, you need to insert it on grapesjs init, something like that: Or if you want to include css inline:
@JulyanoF I tried this solution but this does not load all the classes of all my web pages.. it just loads all of the results page and few classes from other pages
deleted few classes[ unable to understand why so ] Not used classes are not rendered The suggestion proposed by @JulyanoF is the valid oneit just loads all of the results page and few classes from other pages You can use as many styles you need
Related Questions and Answers
Continue research with similar issue discussions.
Issue #1329
Question: How to use same CSS for Multiple pages
Hello Grapejs Team, We've been working on Multi-page Website Builder. For each project there will be multiple html pages with single common...
Issue #783
[QUESTION] Removing certain css
QUESTION My site consists of various webpages like home-page, category-page, results-page etc. The css for all the pages are in a single cs...
Issue #1693
[BUG|/QUESTION] Strange characters (Â) within CSS/HTML preview; Elements are not deleted completely
BUGAre you using the latest release (older versions are NOT supported)?0.14.50Are you facing the bug with your local copy of GrapesJS or wi...
Issue #1621
Question on css classnames used in demo
In the demo page https://grapesjs.com/demo.html, I see that the elements are centered using a class called container-width.Where can I see...
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.