Skip to content

Instantly share code, notes, and snippets.

@lukasschwab
Last active January 20, 2021 22:16
Show Gist options
  • Select an option

  • Save lukasschwab/ada1f929c41dd7ec3657ed73fe48e00a to your computer and use it in GitHub Desktop.

Select an option

Save lukasschwab/ada1f929c41dd7ec3657ed73fe48e00a to your computer and use it in GitHub Desktop.
Handy bookmarklets
// Set GitHub tab width.
javascript:void((function(ts=2){var loc = location.href;loc.indexOf("?")<0?(location.href=loc+`?ts=${ts}`):(location.href=loc+`&ts=${ts}`);})());
// Hide all files marked as "viewed" on GitHub.
javascript:(()=>{var sheet = (function() {var style = document.createElement("style");style.appendChild(document.createTextNode(""));document.head.appendChild(style);return style.sheet;})();sheet.insertRule("[data-file-user-viewed] { display: none; }");})();
// Remove the Share/Highlight popover options when you highlight text on Medium.
javascript:(()=>{document.querySelectorAll("h1, h2, h3, h4, h5, h6, p").forEach(elem => elem.removeAttribute("data-selectable-paragraph"))})();
// Modify playback speed for local media.
javascript:(()=>{document.querySelector('video').playbackRate=2.0;document.querySelector('video').defaultPlaybackRate=2.0;})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment