Uploaded image for project: 'MusicBrainz Server'
  1. MusicBrainz Server
  2. MBS-11889

Refactor state handling in the external links editor

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • JavaScript

      root/static/scripts/edit/externalLinks.js is written as a class-based component with its own state, while sub-components URLInputPopover and ExternalLinkAttributeDialog also have their own state – this requires hacks like having to update the local relationship state inside ExternalLinkAttributeDialog via useEffect.

      All state should be stored in the top-level ExternalLinksEditor; sub-components should receive their "state" as props. ExternalLinksEditor should be converted to a functional (not class-based) component with its own top-level reducer.

            Unassigned Unassigned
            bitmap Michael Wiencek
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Version Package