Skip to content

Feature: Middleware-style exportDOM/importDOM #7259

Open
@etrepum

Description

@etrepum

Description

In many situations what's needed is not to completely override importDOM/exportDOM but to inject some code that runs somewhere in the pipeline, e.g. to add or remove some metadata.

Impact

This will be an enabling feature for NodeState where the state should be serialized to or from the DOM. Currently, only JSON serializations are defined. It would probably make sense to have some sort of default serialization based on data properties, but it doesn't make sense for the serialization of a specific property to require overriding the exportDOM of every class.

The minimal requirement on the export side for something like this would be kind of like a mutation listener, but for export instead of render.

Metadata

Metadata

Assignees

No one assigned

    Labels

    coreReconciler, DOM, Selection, Node, Events, CompositionenhancementImprovement over existing featurehtml

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions