Issue #1157πŸ’¬ AnsweredOpened Jun 1, 2018by krunal0390 reactions

Return span randomly in custom component

Quick answerby artf

Well from what you've posted I can't tell what is happening but definitely, there is nothing generated randomly, just go deeper with the debug. BTW you can solve this easier by using find(query) method:

Read full answer below ↓

Question

I have custom component and on trait change wanted to updated html but randomly it returned span/textnode in trait change function insted of html element. Below is html generated by component and on title change want to updated h4 element.linkModel.get("components").at(0) returns "div.programme-description" correctlylinkModel.get("components").at(1) returns "span" not sure from where it is cominglinkModel.get("components").at(2) returns "span" not sure from where it is cominglinkModel.get("components").at(3) returns "img.programme-content-image" correctlylinkModel.get("components").at(4) retu...

Answers (3)

artfβ€’ Jun 6, 2018

Well from what you've posted I can't tell what is happening but definitely, there is nothing generated randomly, just go deeper with the debug. BTW you can solve this easier by using find(query) method:

krunal039β€’ Jun 7, 2018

@artf I tried to debug but no luck as it is happening on some pages and not on all pages. also

this.find is undefined image

artfβ€’ Jun 14, 2018

Just update grapesjs

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.