Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "frontend-packages/cookie-consent-web-client/src/api/createApi"

Index

Namespaces

Functions

Functions

createApi

  • createApi(manager: CookieConsentManager, blocker: Parameters<typeof unblock>[0]): { wrapFn: apiWrapFn }
  • Create the API functions and make them available through window.consentApi.

    There is also a stub implementation:

    ((a,b)=>{a[b]||(a[b]={},["consentSync"].forEach(c=>a[b][c]=()=>({cookie:null,consentGiven:!1,cookieOptIn:!0})),["consent","consentAll","unblock"].forEach(c=>a[b][c]=(...d)=>new Promise(e=>a.addEventListener(b,()=>{a[b][c](...d).then(e)},{once:!0}))))})(window,"consentApi");
    

    Parameters

    Returns { wrapFn: apiWrapFn }

    • wrapFn: apiWrapFn

Generated using TypeDoc