0.1.1 • Published 4 years ago

@longroad/usercentrics-client v0.1.1

Weekly downloads
-
License
-
Repository
-
Last release
4 years ago

Usercenrtrics Client

Installation

yarn add @consumer/usercentrics-client

Usage

import { UsercentricsProvider, Usercentrics } from '@consumer/usercentrics-client';
import dynamic 'next/dynamic';

const DynamicUsercentrics = dynamic({
  loader: import('@consumer/usercentrics-client').then(mod => mod.Usercenrtrics),
  ssr: false, // Never load this on server side
})

const App = () => {
  return (
    <UsercentricsProvider settingId="SETTING_ID">
      <Usercentrics />
    </UsercentricsProvider>
  );
};

Development

Example app uses relative-deps to link the library. After a new build of the library, run yarn prepare inside the example folder to update the library for the example.

0.1.1

4 years ago

0.1.0

4 years ago