1.4.4 • Published 5 years ago

betterplace-cookies-banner v1.4.4

Weekly downloads
5
License
ISC
Repository
github
Last release
5 years ago

npm Version Dependency Status

betterplace-cookies-banner

Installation

yarn add betterplace-cookies-banner

Usage

Do this in webpacked JS:

import BetterplaceCookiesBanner from 'betterplace-cookies-banner'

Then either call it right away ...

new BetterplaceCookiesBanner()

... or assign it to window and instantiate it somewhere else, e.g. in a layout file.

The constructor can be passed an options argument.

new BetterplaceCookiesBanner({
  acceptCallback: initGoogleAnalyticsFunction,
  link: 'http://my-custom-privacy-doc.com', // only used if no text given
  showInIframe: true, // default: false
  showUntilAccepted: false, // default: true
  text: 'My custom banner text', // should include a privacy doc link
})

NOTE: The banner is currently shown even for doNotTrack=1, overriding the behavior of cookies-eu-banner.

Development

Install development / runtime dependencies:

yarn

Preview:

open preview.html

Release a new version:

yarn publish

1.4.4

5 years ago

1.4.3

5 years ago

1.4.2

5 years ago

1.4.1

5 years ago

1.4.0

6 years ago

1.3.2

6 years ago

1.3.1

6 years ago

1.3.0

6 years ago

1.2.1

6 years ago

1.2.0

6 years ago

1.1.0

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago