Interface ExternalTabConfig<T, P>

interface ExternalTabConfig<T, P> {
    buildOnRegister?: boolean;
    buildTab: ((fullUrl?: string, params?: P) => INavigationBarTab<T, T>);
    configUrl: string;
    doNotReuse?: boolean;
    elementName: string;
    mainTabId?: string;
    sortIndex?: number;
    systemTab?: boolean;
}

Type Parameters

Properties

buildOnRegister?: boolean

Set this to true if you want buildTab to run when registered (e.g. for a system tab that's always there). If your buildTab takes params, this cannot be provided and must be assumed undefined. A secondaryTab (one that has mainTabId) will be created regardless of this flag.

buildTab: ((fullUrl?: string, params?: P) => INavigationBarTab<T, T>)

Function to return INavigationBarTab. Remember routeUrl is from baseURL with a leading /. fullUrl is the full URL that relates to the tab, useful when catching wildcards. params is constructed as of /:param1/:param2, so {param1: string, param2: string}. Be aware fullUrl/params will be undefined if buildOnRegister is true.

configUrl: string

This is the URL that the tab will be registered under. Technically it's just a unique ID as this will be used to unregister a route and close any related tab(s).

doNotReuse?: boolean

Set this to true if you want the component to reset every time you navigate away.

elementName: string

This is the element/tag name that will be presented.

mainTabId?: string

Finds TabId, and adds this as a secondaryTab to that tab.

sortIndex?: number

Will try to place at this index, can be negative, fraction, etc. to put before/between existing tabs.

systemTab?: boolean

Add as a system tab. If left out will default to application tab, ignored if mainTabId is defined.