Skip to content

Instantly share code, notes, and snippets.

@chunrapeepat
Last active October 14, 2022 15:37
Show Gist options
  • Save chunrapeepat/7d8b793df3b04512ba2ea0ff9320ad24 to your computer and use it in GitHub Desktop.
Save chunrapeepat/7d8b793df3b04512ba2ea0ff9320ad24 to your computer and use it in GitHub Desktop.
Chrome designMode bookmarklet
javascript:(
function () {
if (document.designMode === "off") {
document.designMode = 'on';
document.body.innerHTML += `<div id="dmbml" style="position:fixed;z-index:99999;background:white;color:black;top:-1px;left:-1px;border: 1px solid #ccc;font-family:sans-serif;">🎨 Design Mode = On<div>`;
void 0;
} else if (document.designMode === "on") {
document.designMode = 'off';
document.getElementById('dmbml').remove();
void 0;
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment