Skip to main content
cngx-src documentation

withTabsRouteMatch

Functioncommon/tabs

projects/common/tabs/tabs-config.ts

Description#

Force one URL-matching mode app-wide for [cngxTabsRouteSync].
'suffix' treats every tab as a leaf route, 'prefix' as a section that stays active for URLs beneath it.

Reach for this only when the host-flavour default is wrong for your app. Unset, a <cngx-tab-nav> matches by prefix and a <cngx-tab-group> by suffix, which is what each markup implies; this feature overrides both. Per-instance [match] still wins.

Changes which policy runs, not the policies themselves - swap those via CNGX_TAB_URL_MATCH_STRATEGY.

Signature#

withTabsRouteMatch(mode)

Parameters#

@parammode

Returns#

CngxTabsConfigFeature