Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "frontend-packages/cookie-consent-web-client/src/predecision/gateway"

Index

Type aliases

PreDecisionGateway

PreDecisionGateway<Arguments>: (options: PreDecisionGatewayOptions, ...args: Arguments) => Promise<PreDecisionGatewayResult | false>

Type parameters

  • Arguments: any[] = any[]

Type declaration

PreDecisionGatewayOptions

PreDecisionGatewayOptions: Pick<CookieConsentManagerOptions, "decisionCookieName" | "revisionHash" | "supportsCookiesName" | "groups" | "essentialGroupSlug">

This options are available to all predecision gateways.

PreDecisionGatewayResult

PreDecisionGatewayResult: "all" | "essentials" | "dnt" | "consent" | "nothing"

Functions

preDecisionGateway

  • Type parameters

    • Arguments: any[] = any[]

    Parameters

    • options: (PreDecisionGatewayOptions & Omit<GetServiceSelectionOptions, "type">) | CookieConsentManager
    • handler: { args: Arguments; gateways: PreDecisionGateway<Arguments>[]; onIsDoNotTrack: (apply: () => Promise<void>) => void; onShowCookieBanner: () => void }
      • args: Arguments
      • gateways: PreDecisionGateway<Arguments>[]
      • onIsDoNotTrack: (apply: () => Promise<void>) => void

        If do not track is returned by a predecision gateway, you should save the state in your API and call the apply function manually.

          • (apply: () => Promise<void>): void
          • Parameters

            • apply: () => Promise<void>
                • (): Promise<void>
                • Returns Promise<void>

            Returns void

      • onShowCookieBanner: () => void

        No predecision is set, so we should show a visual cookie banner.

          • (): void
          • Returns void

    Returns Promise<void>

Generated using TypeDoc