Skip to content

Listen to children's change in src= #4

@lourot

Description

@lourot
<ImageDisplayControl>
  <Image src=... />
</ImageDisplayControl>

In case the child's src= is constructed for example based on its state, updated later asynchronously by a useEffect(), we (the parent <ImageDisplayControl>) won't notice the change, and so we won't fetch the new image regions corresponding to the new image.

How to solve this? With a MutationObserver? With some kind of subscription to the children's React states?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions