Skip to content

Question: how to handle reconnect properly? #5

@zhaoyao91

Description

@zhaoyao91

Standard web component has 3 key lifecycle point: create(constructor), connected, disconnected. This is because an element may be remove from dom and added back again and again. With these hooks, we could create something in constructure but reuse them from time to time.

But lifecycles defined by this repo are only create and release, which means we have to recreate all thing after reconnecting.

Am I missing something? Or how could we handle this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions