Przejdź do głównej zawartości

Function: createClearTokenHandler()

createClearTokenHandler(options?): (request) => Promise<Response>

Create a POST handler that clears the auth token cookie.

Security: origin validation, immediate expiration (maxAge=0).

Pass isTrustedOrigin when running behind a reverse proxy that strips or rewrites the Host header — see trustedForwardedHostValidator.

Parameters

options?

ClearTokenHandlerOptions

Returns

(request) => Promise<Response>