Issue #1770✓ SolvedOpened January 31, 2019by a-bashtannik2 reactions

Components with custom tag are not rendered if specified in theme body

Quick answerby artf2

There are 2 issues:You forgot to specify isComponent (used in the parsing process)Currently, new component types are not working for the initial template, so the only way is to add them via plugins (I didn't find time to see why it's happening) https://jsfiddle.net/m8hkuza3/

Read full answer below ↓

Question

Hello I created very simple skeleton of GrapesJS editor. HTML template: Javascript: Result of loading: As you see, component is not rendered. But if I drop blocks manually, everything is ok: If I change template and set data-gjs-type attribute to <test-tag data-gjs-type="test-component-type"></test-tag> value, everything works too. I tried also construction with isComponent defined but with the same result. Custom tags, specified in templates are not rendered on page load. Looks like bug, or maybe I'm wrong somewhere and additional render calls required? Thanks.

Answers (3)

👍 Most helpfulartfFebruary 6, 2019

There are 2 issues:You forgot to specify isComponent (used in the parsing process)Currently, new component types are not working for the initial template, so the only way is to add them via plugins (I didn't find time to see why it's happening) https://jsfiddle.net/m8hkuza3/

a-bashtannikFebruary 6, 2019

@artf , thank you for your answer, but I also

tried also construction with isComponent defined but with the same result.

whatever, I implemented this feature via plugins as you mentioned.

Have no idea why new component types don't work too, I will crate a PR if will figure out.

lock[bot]February 6, 2020

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

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.