Issue #2483💬 AnsweredOpened December 31, 2019by andrewryan19061 reactions

Default model names not persisting to local storage

Quick answerby pouyamiralayi1

@andrewryan1906 please define your component type inside a plugin. cheers!

Read full answer below ↓

Question

When I create a new Dom Component, I give it a name in the "defaults" section, like: When the component is dragged on to the canvas, the Foo Bar string shows up as a badge like it should, and the text appears in the Layers panel and everything is good. But when the canvas is persisted to storage, and I refresh the page, the badge now shows the ugly-type-name, and it appears in the layers as well. What am I doing wrong?

Answers (2)

pouyamiralayiDecember 31, 2019

@andrewryan1906 please define your component type inside a plugin. cheers!

andrewryan1906January 2, 2020

That works, thanks!

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.