1.1.2 • Published 7 years ago

donottrack v1.1.2

Weekly downloads
34
License
MIT
Repository
github
Last release
7 years ago

do-not-track

Accessing the user's preferences in terms of tracking can be slightly complicated. This module simplifies that.

Install

npm install --save donottrack

Usage

Browser:

import doNotTrack from 'donottrack';

// Returns true if the user agrees to being tracked, false otherwise.
const mayTrack = doNotTrack(/* default, if preferences are not set. */ true);

Node:

import doNotTrack from 'donottrack';

const mayTrack = doNotTrack(req.header('DNT'), true);
1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.0

8 years ago