Skip to content

Instantly share code, notes, and snippets.

@kolyanok
Last active April 11, 2017 22:17
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 kolyanok/ec00d255a528918ff5c0897432f7c54f to your computer and use it in GitHub Desktop.
Save kolyanok/ec00d255a528918ff5c0897432f7c54f to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name NePoehavshiTJ
// @include https://tjournal.ru/*
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js
// @grant GM_addStyle
// @grant GM_xmlhttpRequest
// ==/UserScript==
var badCSS = $("link[href*='main.min.css']");
var badURL = badCSS.attr ("href");
badCSS.remove ();
GM_xmlhttpRequest ( {
method: "GET",
url: badURL,
onload: function (rsp){
var betterCSS = rsp.responseText.replace (
/min-width:1340px/g, "display: none"
);
betterCSS = betterCSS.replace(/\.\.\//g, "/static/main/");
GM_addStyle (betterCSS);
}
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment