[QUESTION] Change the html content of the selected component
Question
I am trying to replace the html of the basic Text componet using the below code
const component = editor.getSelected(); component.set('content', 'Test');
It gets changed in the canvas but the code still has 'Insert Your text here' appended to it as shown in the below image.

Answers (1)
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.
Issue #1290
[BUG]Set href for link block not editable once initialized
#1277 is closed but issue still exist so i have to post as new issue Thank you for the help for earlier @maryia-kabash @artf I have made a...
Issue #1327
[QUESTIONS] Replacing selected text and getting html
Hi! Im trying to replace selected text with a code (random code). It's works, i can see the code, but when i do editor.getHtml() not. If i...
Issue #463
Is the video component on the webpage demo working?
I wanted to study how to use the video component but the one on the demo website (http://grapesjs.com/demo.html) doesn't seem to be working...
Issue #1429
Empty content when load from remote storage if components array is not empty
I have problem loading stored remote content into the editor when the JSON contains non empty gjs-components My JSON data looks like this w...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.