Support rendering layouts which are not part of the editable content
For the point 1 you can pass this to your init options: Point 2, what about something like a custom placeholder component which just overwrites toHtml method in the model definiton
Read full answer below ↓Question
Basically my use case is that I want to show a whole page - with header, menu(s) and footer - in the editor canvas, but only allow the user to edit the actual content of it. The reasoning behind this is so that the users can see the page as close as it will be to the "end product". I've been able to accomplish something like this by rendering the full page into the wrapper, using the fromElement option, and taking care to set highlightable, badgable and all the other such attributes to false on the elements belonging to the layout, but still this is not ideal as:The root node in the "Layer Ma...
Answers (3)
For the point 1 you can pass this to your init options: Point 2, what about something like a custom placeholder component which just overwrites toHtml method in the model definiton
Hey @dsgh, did you manage to accomplish your task?
@artf These past few days I've been busy working on other extensions to grapesjs that we're also needing. Thank you for your suggestions here - I'll investigate more about the showWrapper option, and I think your suggestion for point 2 is spot on! I should have thought of doing that. I'll return to...
Related Questions and Answers
Continue research with similar issue discussions.
Issue #336
[Question] How to disable editing on fetched content
Hi, i want to integrate your project into an existing webpage as a kind of CMS-editor. It is necessary for the editor to wrap the whole bod...
Issue #2238
[QUESTION] How to get style for header & footer components only
Hi @artf, can you please tell me what is the fastest and easies way to extract component styles. I have template and in this template you c...
Issue #3046
QUESTION: How to keep default sections in the canvas without the possibility to be removed by the user?
I want to generate a PDF Tool to have three main sections: HEADER, BODY and FOOTER. The three sections needs to be there always and I want...
Issue #2909
FEAT: Support for search and commands in the editor for custom components
Hi. First of all, awesome work with grapesjs. Had a feature request which may greatly improve usability for users. While grapesjs does allo...
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 →Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.