[Questions] getHtml grapesjs web builder
Question
I have a problem in getHtml. I add an icon in the button, in the web the icon is visible, and when in the inspect element there is an icon object, but when in getHtml it uses the editor.getHtml() function, the icon disappears.
Object icon

result editor.getHtml() :

Answers (2)
getHtml is based on the component model data, you probably just changing its view data (eg. this.$el.append('<i class="fa ...')). Read carefully this part https://grapesjs.com/docs/modules/Components.html
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 #792
Script property using function don't work with blocks
In Components & JS docs there's this example: This works perfectly. But I couldn't use a function instead of a string in script, as is said...
Issue #563
Table <thead> and <tbody> tag gets Omitted
Hello, There is new issue with GrapesJS (maybe). I've created new component using bm.add() in which I've used a table element with <thead>...
Issue #687
After update the component attributes using editor.on('component:add',function(){}); The blue box item is not correct.
After update the component attributes using editor.on('component:add',function(){}); The blue box item(it mean the action icon) is not corr...
Issue #1930
[QUESTIONS] change 2 attributes with 1 trait
I have an input trait, I want to change the 2 attributes (name and type) on the selected input element, on canvas is appropriate, but in th...
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.