Skip to content

Instantly share code, notes, and snippets.

@nikhilw
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nikhilw/dbfc1e14cd48bb943cb8 to your computer and use it in GitHub Desktop.
Save nikhilw/dbfc1e14cd48bb943cb8 to your computer and use it in GitHub Desktop.
Bookmarklet for one-click config of devdocs.io
// For those who have the habit of clearing cookies. this sets the cookie for devdocs.io config.
// modify the 'docs' list to match your requirements.
// Heres the code for the bookmarklet.
(function () {
var d = new Date();
d.setTime(d.getTime() + (21 * 24 * 60 * 60 * 1000));
document.cookie = "docs=backbone/css/git/grunt/html/http/javascript/jquery/jqueryui/node/requirejs/angular/express/lodash/markdown/mocha/mongoose/underscore/chai;" +
"Host=devdocs.io;"+
"Path=/;"+
"Send For=Any type of connection;"+
"Expires=" + d.toGMTString();
})();
// Heres the bookmarklet.
// Create a new bookmark and paste the below as location.
javascript:(function(){var%20d=new%20Date();d.setTime(d.getTime()+(21*24*60*60*1000));document.cookie="docs=backbone/css/git/grunt/html/http/javascript/jquery/jqueryui/node/requirejs/angular/express/lodash/markdown/mocha/mongoose/underscore/chai;Host=devdocs.io;Path=/;Send%20For=Any%20type%20of%20connection;Expires="+d.toGMTString();})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment