Review 13.4 Merged

89201[BUGFIX] Check state in web components extending `HTMLElement`

Andreas Kienast CR +2 V +2 Normal +55 −10 updated 04/23/25, 13:06

Commit message

Web components that extend `HTMLElement` directly suffer from poor
lifecycles as `connectedCallback()` is called when the component is
added into the DOM, and when it is moved. This causes several issues,
e.g. double initialization or stacked event listeners.

This is a major issue in FormEngine as IRRE elements may get re-ordered
and thus the position of their children change in the DOM, calling
`connectedCallback()` again.

To solve this issue in FormEngine context for now, internal state is
checked and futher processing is aborted, if suitable.

Review

  • Code review CR +2 Done
    • Andreas Kienast +2
  • Verified V +2 Done
    • Andreas Kienast +2
    • core-ci +1 CI

Issues 1

Files 18

Review log 34

  1. Andreas Kienast uploaded patch set 1 04/23/25, 10:52

  2. core-ci voted on patch set 1 V +1 04/23/25, 10:59 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/78060

  3. Andreas Kienast voted on patch set 1 CR +2 V +2 04/23/25, 13:06

  4. Andreas Kienast merged patch set 2 04/23/25, 13:06