Skip to content

Instantly share code, notes, and snippets.

@davzoku
Created June 6, 2021 15:13
Show Gist options
  • Save davzoku/6ef124999de305f3cf08afd52f445c8e to your computer and use it in GitHub Desktop.
Save davzoku/6ef124999de305f3cf08afd52f445c8e to your computer and use it in GitHub Desktop.
Use your browser as your notepad. Fuss-free!

Quick Notepad in Browser

Ever wish that you can turn your browser into a quick writing pad just to store some temporary strings of data?

This can be done by using the contenteditable attribute that is supported by most modern browser. Just copy the following code snippet in the browser omnibar and type away

Tip 1: save the following snippet as a bookmark and you can access it quickly via the bookmarks bar.

Tip 2: This should be used for temporary data that you don't mind losing. The notes will not be saved anywhere, unless you do a CTRL + S to save the webpage.

Dark Mode

data:text/html;charset=utf-8, <title>Notepad</title><body OnLoad='document.body.focus();'  contenteditable style="font-size:21px;line-height:1.6;font-family:Consolas, 'Courier New', monospace;background-color:rgb(0,0,0);color:rgb(255,255,255);" spellcheck="true">

Basic Mode

data:text/html <html contenteditable>

References: http://www.vcarrer.com/2013/01/writability-write-in-your-browser.html

@neonwatty
Copy link

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment