Skip to content

Provide a way to reload a failed async component #9788

Closed
@Maorey

Description

@Maorey

What problem does this feature solve?

Local register a async component by a factory function that return an object to handling loading state. But when the promise is rejected, there will be always show error component and no any way to reload it.

What does the proposed API look like?

  1. Recall the factory function on parent's next active/update hook when rejected
  2. [Recommend]Accept more options to handle loading state such as provide an 'on' to
    listen replaced component's(loading/error) events and the event context allows to change loading state(rerend, of course)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions