Skip to content

Instantly share code, notes, and snippets.

@SilverEzhik
Last active February 12, 2019 05:02
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 SilverEzhik/d1c2cb78fee6895fb74e89b974c76af6 to your computer and use it in GitHub Desktop.
Save SilverEzhik/d1c2cb78fee6895fb74e89b974c76af6 to your computer and use it in GitHub Desktop.
A strange game. The only winning move is not to play.
// ==UserScript==
// @name Discourse Enhancer
// @description A strange game. The only winning move is not to play.
// @version 1
// @run-at document-start
// @grant none
// @include *://*reddit.com/r/all/
// @include *://news.ycombinator.com/item*
// @include *://news.ycombinator.com/login*
// ==/UserScript==
window.stop();
console.log("kinshi");
let placeholder = `
<head>
<meta charset="utf-8" />
<style>
* {
display: none;
}
html {
display: inherit;
}
body {
display: flex;
margin: 0;
justify-content: center;
align-items: center;
height: 100vh;
}
a {
display: block;
font-size: 72px;
text-decoration: none;
border-bottom: 1px solid transparent;
color: #48f;
}
a:hover {
text-decoration: underline;
}
</style>
</head>
<body>
<a href="javascript:history.back()">帰れ</a>
</body>
`;
document.querySelector("html").innerHTML = placeholder;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment