Skip to main content

Interface: FetchOptions

@headstartwp/core.FetchOptions

The options supported by the default fetcher method

Properties

alternativePreviewAuthorizationHeader

Optional alternativePreviewAuthorizationHeader: boolean

Flag to enable using the alternative authorization header.

This can be useful if you have separate authentication on your project.

Defined in

packages/core/src/data/strategies/AbstractFetchStrategy.ts:82


bearerToken

Optional bearerToken: string

The authentication token to use for the request.

Defined in

packages/core/src/data/strategies/AbstractFetchStrategy.ts:68


burstCache

Optional burstCache: boolean

Whether to burst cache by appending a timestamp to the query

Defined in

packages/core/src/data/strategies/AbstractFetchStrategy.ts:87


previewToken

Optional previewToken: string

The preview token to use for the request.

These are tokens issued by the HeadstartWP plugin and is used to authenticate previews

Defined in

packages/core/src/data/strategies/AbstractFetchStrategy.ts:75


throwIfNotFound

throwIfNotFound: boolean

Whether to thrown an exception if data is not found.

Defined in

packages/core/src/data/strategies/AbstractFetchStrategy.ts:63