Interface Commands

interface Commands {
    component<K>(name: K): HTMLElementTagNameMap[K];
    component(name: string): HTMLElement;
    prevent(): PreventResult;
    redirect(path: string): RedirectResult;
}

Methods

  • Type Parameters

    • K extends keyof HTMLElementTagNameMap

    Parameters

    • name: K

    Returns HTMLElementTagNameMap[K]

  • Parameters

    • name: string

    Returns HTMLElement

  • function that creates a special object that can be returned to abort the current navigation and fall back to the last one. If there is no existing one, an exception is thrown.

    Returns PreventResult