c15t
/
C15T Logo
DocsFrontendIntegrationsSelf HostChangelog

x

bsky

discord

github1.4k
arrow-leftBack to Changelog
Nov.14, 20254.005 min read

v1.8.0 - Cross-Subdomain Consent, Legal Links, User Identification & EU Languages

Posted By

Kaylee
consent-icon-rounded
Kaylee
@kaylee_dev

✨ New Features

Hybrid Cookie/LocalStorage Approach for consent

This update changes how we store consent in the browser, from using local-storage only to a hybrid approach with both cookies & local storage.

Cookies will now allow you to check consent on the server side & persist consent across subdomains e.g. dashboard.example.com & example.com.

To enable this, you use the storageConfig option.

<ConsentManagerProvider
  options={{
    storageConfig: {
      storageKey: 'my-consent', // Custom override for local storage + cookie key 



C15T Logo
Leverage native React components for seamless integration and high performance in a robust Consent Management solution that empowers your development team while prioritizing privacy and compliance.
Product
  • Documentation
crossSubdomain: true,
},
}}
>

Existing consent under the old privacy-consent-storage key will be automatically migrated to the new c15t key.

Configurable Legal Links

You can now add various legal links to the consent manager. This can be used to display links in the consent banner, dialog, etc.

<ConsentManagerProvider
  options={{
    legalLinks: {
      privacyPolicy: { href: '/privacy-policy' },
      termsOfService: { href: '/terms-of-service' },
      cookiePolicy: { href: '/cookie-policy' },
    },
  }}
>

You can filter what legal links you want to display (if any) on the pre-made components by passing the legalLinks prop.

// Show no legal links (default)
<CookieBanner />

// Show both cookie policy and terms of service
<CookieBanner legalLinks={['cookiePolicy', 'termsOfService']} />
Legal Links BannerLegal Links Dialog

User Identification

We've enabled user identification in the consent manager. This allows you to link a user's ID to a consent record both before & after consent is given.

An external ID can be set in various ways:

<ConsentManagerProvider
  options={{
    user: {
      id: 'usr_foobar',
      identityProvider: 'better-auth',
    }
  }}
>

// Or via the `identifyUser` method in the Store
const { identifyUser } = useConsentManager();

identifyUser({
  id: 'usr_foobar',
  identityProvider: 'better-auth',
});

This change also brings a new endpoint to the backend: PATCH /consent/identify. So you'll need to update your backend to support this new endpoint.

All 24 Official Languages of the European Union

We've added support for all 24 official languages of the European Union as well as additional languages to the translations package bringing the total number of supported languages to 33.

Current languages include:

Bulgarian (bg)Czech (cs)Danish (da)German (de)Greek (el)English (en)Spanish (es)
Estonian (et)Finnish (fi)French (fr)Irish (ga)Hebrew (he)Croatian (hr)Hungarian (hu)
Indonesian (id)Italian (it)Lithuanian (lt)Latvian (lv)Maltese (mt)Dutch (nl)Polish (pl)
Portuguese (pt)Romanian (ro)Slovak (sk)Slovenian (sl)Swedish (sv)Chinese (zh)Welsh (cy)
Icelandic (is)Luxembourgish (lb)Norwegian Bokmål (nb)Norwegian Nynorsk (nn)Romansh (rm)

Script Loader Target Location

The script loader now supports specifying the target location of the script in the DOM. This is useful for scripts that need to be loaded in the body of the document.

This can be done with the target option, which defaults to head if not specified.

{
  id: 'example',
  src: 'https://analytics.example.com/script.js',
  category: 'analytics',
  target: 'body',
}

Overriding Country, Region & Language

You can now override the country, region & language of the consent manager. This overrides the headers sent to the backend, allowing for better testing, this also works in offline mode.

<ConsentManagerProvider
  options={{
    overrides: {
      country: "DE",
      region: "BE",
      language: "de",
    }
  }}
>

🐛 Bug Fixes & Improvements

@c15t/scripts

  • Added new Databuddy prebuilt script
  • Updated dependencies

@c15t/nextjs

  • Ensure all exports from core are re-exported
  • Updated dependencies

@c15t/react

  • Ensure all exports from core are re-exported
  • Updated dependencies

c15t

  • Updated dependencies

@c15t/translations

  • Updated dependencies

@c15t/scripts

  • Updated dependencies

@c15t/cli

  • Updated dependencies

@c15t/backend

  • Updated dependencies

@c15t/node-sdk

  • Updated dependencies

@c15t/dev-tools

  • Updated dependencies

Thank you to our contributors

, , , ,

  • Components
  • Company
    • GitHub
    • Contact
    Legal
    • Privacy Policy
    • Cookie Policy
    c15t

    Thank you to our contributors

    @KayleeWilliams, @BurnedChris, @izadoesdev, @djmisha, @davidturnbull