Skip to main content
Version: 14.1

Class: SpectacularFeatureLocation

A subset of Angular's Location service adjusted to the Angular feature module under test.

Constructors

constructor

new SpectacularFeatureLocation()

Methods

path

path(includeHash?): string

Normalizes the URL path for this location. URLs within the Angular feature module under test are prefixed with tilde (~).

Wraps Location#path.

Parameters

NameTypeDefault valueDescription
includeHashbooleanfalseTrue to include an anchor fragment in the path. Optional. Default is false.

Returns

string

Defined in

packages/spectacular/src/lib/feature-testing/navigation/spectacular-feature-location.ts:26