This works for a Neocities website without a custom domain.
This should also work for a site with a custom domain, but I haven't tested it.
In the end, you'll get something like this:
// if we don't use setTimeout, safari will crash. i don't know why. | |
setTimeout(() => { | |
document.body.innerHTML = `<iframe id="frame" src="/" style="position: fixed; width: 100%; height: 100%; top: 0; left: 0; border: none;">`; | |
document.head.innerHTML = `<title>TETR.IO</title>`; | |
document.body.style.background = "black"; | |
const script = ` | |
(() => { | |
let oldXMLHttpRequest = window.XMLHttpRequest | |
let oldAudio = window.Audio; | |
const nothing = "https://tetr.io/res/bgm/kuchu-toshi.mp3?blank"; |
// ==UserScript== | |
// @name 3D DOM viewer | |
// @namespace https://gist.github.com/hf02/2f2fb776ba233fd758af559b9de9e177 | |
// @version 2024-03-27 | |
// @description 3D DOM viewer | |
// @author OrionReed (forked by hf02) | |
// @match *://*/* | |
// @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== | |
// @grant GM_registerMenuCommand | |
// ==/UserScript== |