Skip to content

Instantly share code, notes, and snippets.

@cor3ntin
Created April 24, 2021 13:45
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 cor3ntin/10c80fc2048ce2f1338b1d3b264f4f38 to your computer and use it in GitHub Desktop.
Save cor3ntin/10c80fc2048ce2f1338b1d3b264f4f38 to your computer and use it in GitHub Desktop.
Fix underscore on eel.is
// ==UserScript==
// @name eel.is.noshy
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Remove &shy from eel.is
// @author cor3ntin
// @match http://eel.is/c++draft/*
// @icon https://www.google.com/s2/favicons?domain=eel.is
// @grant none
// ==/UserScript==
(function() {
const source = document
source.addEventListener('copy', (event) => {
const selection = document.getSelection();
const txt = selection.toString().replace(/\u00AD/g, "");
event.clipboardData.setData('text/plain', txt);
event.clipboardData.setData('text/html', txt);
event.preventDefault();
});
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment