Issue #3172πŸ’¬ AnsweredOpened Dec 8, 2020by theSC0RP0 reactions

How to track the updates of components down the tree?

Quick answerby artf

I'd create a specific listener on the parent then I'd trigger that event from the child

Read full answer below ↓

Question

Hi, @artf. I have a few questions regarding component lifecycle hooks. In my application, I want to track the updates to all the children of a component and their children, and so on. How should I do it?Updates on immediate children are tracked by the model.updated() hook but I need to track the updates to a component (let's call this a super child) which is a nested child of some other component (let's call this super parent). In between the super parent and the super child, there can be any number of components. How can I track these updates? e.g. If I add a component to the super child, I...

Answers (2)

artfβ€’ Dec 14, 2020

I'd create a specific listener on the parent then I'd trigger that event from the child

GJSBlockβ€’ May 17, 2026

Thanks for reporting this, @theSC0RP. Great question about How to track the updates of components down the tree?. The recommended approach with Components is to use the event-driven API. Start here: Check the GrapesJS documentation for your specific module Look for the on() event listener method Mo...

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.