Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/farski/donottrack
https://github.com/farski/donottrack
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/farski/donottrack
- Owner: farski
- License: mit
- Created: 2011-05-14T02:48:31.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2011-05-25T01:03:50.000Z (over 13 years ago)
- Last Synced: 2024-11-15T16:32:59.129Z (2 months ago)
- Language: Ruby
- Homepage:
- Size: 107 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# donottrack
Simple rack middleware utility to make sure the upcoming standard DNT header is always available. This will normalize things like the X-Do-Not-Track header that may be floating around, allow for server override, and default to 0 (allow tracking, the proposed browser default) if there's no better option.
### Installation
gem install donottrack
### Usage
# Default behavior
use Rack::DoNotTrack
# Manual override (always enable do not track)
use Rack::DoNotTrack, 1
Both of these will ensure that, in Rails for instance, request.headers['HTTP_DNT'] will always be available.## Copyright
Copyright (c) 2011 Chris Kalafarski. See LICENSE.txt for further details.