Issue #6296πŸ’¬ AnsweredOpened Nov 5, 2024by maneeshp970 reactions

Custom react components gets wrapped inside a div

Quick answerby artf

Yeah, that's expected from the demo perspective. You can play around with the code and find your solution but I'm closing this as it's not a core bug.

Read full answer below ↓

Question

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Arc v1.61.1 Reproducible demo link https://codesandbox.io/s/grapesjs-react-components-n6sff Describe the bug @artf First of all thank you for this amazing library. I was trying to create custom react components within grapesjs and came across this sandbox link from one of the previously reported issues related to react integration. [https://codesandbox.io/s/grapesjs-react-components-n6sff] I was able to make custom react components work after referring the sandbox, however there is one problem tha...

Answers (2)

artfβ€’ Nov 5, 2024

Yeah, that's expected from the demo perspective. You can play around with the code and find your solution but I'm closing this as it's not a core bug.

GJS Helperβ€’ May 17, 2026

The behavior you're observing, where custom React components are wrapped inside an extra div with GrapesJS-specific attributes, is fundamental to how GrapesJS manages components in the DOM. This div is not an "extra" wrapper in the GrapesJS context; it is the GrapesJS component itself. Root Cause E...

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins β†’
Premium option

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.

All tutorials β†’

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.