Show HN: Minimalist editor that lives in browser, stores everything in the URL
468 points| medv | 3 months ago |github.com | reply
What it does:
Single HTML file, no deps, 111 loc
Notes live in the URL hash (shareable links!)
Auto-compressed with CompressionStream
Plain-text editor (contenteditable)
History support
Page title from first # heading
Respects light/dark mode
No storage, cookies, or tracking
The entire app is the page source.
[+] [-] gnyman|3 months ago|reply
I needed a way to share a link to a map, with drawings and the ability for the receiver to see their own location on the map.
Annotated screenshots solves the first but not the second.
Vibe engineered this, with many of the same ideas as OP.
Took an evening. Just in time apps for one specific use case is a thing.
And because it's so cheap to make and can be hosted cheaply with no backend, it can be given away for free.
https://nyman.re/mapdraw/#l=60.172108%2C24.941458&z=16&d=LU8...
[+] [-] mathgeek|3 months ago|reply
While I'm all for vibe coding as appropriate, there's a lot of humor to be found it calling it engineering. :D
[+] [-] gnyman|3 months ago|reply
[+] [-] zenmac|3 months ago|reply
Is the code open source online somewhere?
[+] [-] ronancremin|2 months ago|reply
[+] [-] nextaccountic|3 months ago|reply
And if you are open to bug reports.. if I move around the drawings move smoothly with the map, but if I zoom in/out the drawings move only after the map zooming animation ends, rather than smoothly
[+] [-] antman|3 months ago|reply
Could we also add text annotations? Also the delete button could delete just the last shape or a selected shape so as not to start over?
[+] [-] ninalanyon|3 months ago|reply
In Vivaldi location tracking doesn't work. Version 7.7.3851.66 (Official Build) (64-bit) Chromium Version 142.0.7444.245 Extended Stable channel (may also include additional security patches) Channel Official Build Platform / OS Linux - linuxmint 21.3
And in Firefox 146.0.1 on the same machine the URL doesn't get updated.
[+] [-] nolito|3 months ago|reply
[+] [-] blntechie|3 months ago|reply
[+] [-] piffey|3 months ago|reply
[+] [-] RandomDistort|3 months ago|reply
[+] [-] getupyang|3 months ago|reply
[+] [-] Gehinnn|3 months ago|reply
[+] [-] maxloh|3 months ago|reply
> It is RECOMMENDED that all senders and recipients support, at a minimum, URIs with lengths of 8000 octets in protocol elements. Note that this implies some structures and on-wire representations (for example, the request line in HTTP/1.1) will necessarily be larger in some cases.
Mainstream browsers support at least 64,000 characters [1], and Chrome supports up to 2MB [2].
[0]: https://www.rfc-editor.org/rfc/rfc9110#section-4.1-5
[1]: https://stackoverflow.com/a/417184/
[2]: https://chromium.googlesource.com/chromium/src/+/HEAD/docs/s...
[+] [-] medv|3 months ago|reply
Here is the Crime and Punishment by Fyodor Dostoevsky:
- https://medv.io/goto/crime-and-punishment-by-fyodor-dostoevs...
[+] [-] berkes|3 months ago|reply
It's truly insane how large typical share-URLS for content on instagram, youtube or any other large platforms are. URLs that could've been example.com/t/some-large-enough-id?time=13337 are stuffed with hundreds of characters, just to gather more data on people using these links.
[+] [-] dspillett|3 months ago|reply
> It is RECOMMENDED that all senders and recipients support, at a minimum, URIs with lengths of 8000 octets in protocol elements.
It is always worth remembering that, unless you have already ensured that the content has been rendered into a URI-safe subset of ASCII, a character and an octet are not the same thing.
[+] [-] mrweasel|3 months ago|reply
[+] [-] roxolotl|3 months ago|reply
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
[+] [-] gabrielsroka|3 months ago|reply
https://gabrielsroka.github.io/webpages/calc.htm#a1:=Rate=3....
More examples https://gabrielsroka.github.io/webpages/It's about 130 js loc
[+] [-] growt|3 months ago|reply
[+] [-] 101008|3 months ago|reply
They can't track every website with the link and ask to be removed, either.
Could they ask textarea.my to not parse the link and thus, not display the content? Could textarea.my refuse?
[+] [-] singiamtel|3 months ago|reply
Your example sounds like stopping notepad from rendering copyrighted content
[+] [-] tnecio|3 months ago|reply
[+] [-] fsmv|3 months ago|reply
[+] [-] rfl890|3 months ago|reply
[+] [-] gettingoverit|3 months ago|reply
Edit. Call me a hater, but... I know the guy! That's the guy from Google whose code never works in the most hilarious ways! See issues on the rest of his pinned repos.
[+] [-] levmiseri|3 months ago|reply
[+] [-] omoikane|3 months ago|reply
[+] [-] WD-42|3 months ago|reply
[+] [-] wingtw|3 months ago|reply
Aand im dropped back to empty editor with just that one character visible
(Firefox 146.0.1 (Build #2016132551), 86bb7f6af6312ba3c0161085f854bcdff68f1a91 GV: 146.0.1-20251217121356 AS: 146.0.2 OS: Android 14)
[+] [-] surrTurr|3 months ago|reply
[+] [-] antman|3 months ago|reply
[+] [-] zahlman|3 months ago|reply
[+] [-] ctenb|3 months ago|reply
[+] [-] planb|3 months ago|reply
https://github.com/planbnet/guitartabs
[+] [-] nickweb|3 months ago|reply
The Crime and Punishment one consistently crashes Brave mobile for me. I assume it's the length of the URL - and seen another commentator say the same for chrome mobile (sure they both use the same codebase so likely an upstream issue).
[+] [-] samcollins|3 months ago|reply
https://gist.github.com/smcllns/8b727361ce4cf55cbc017faaefbb...
[+] [-] qingcharles|3 months ago|reply
data:text/html,<title>Notepad</title><textarea autofocus spellcheck=0 style="position:fixed;inset:0;padding:1em;border:0;font:monospace">
Your text actually survives a reboot in Chrome.
Can anyone think of a way to store the textarea value in the URL? I tried using JS to set a # but it's nonsensical in this context.
Edit: here's the best I could do:
data:text/html,<title>Notepad</title><textarea id=t autofocus spellcheck=0 style=position:fixed;inset:0;padding:2em;border:0;font:monospace></textarea><a id=s style=position:fixed;top:10px;right:10px>Right-click Open to save...</a><script>[,P,S]=location.href.slice(15).match(/(.<textarea[^>]>)[^]?(<\/textarea>.)/),t.oninput=U=_=>s.href='data:text/html,'+P+encodeURIComponent(t.value.replace(/&/g,'&').replace(/<\/textarea/g,'</textarea'))+S,U()</script>
[+] [-] ooxoo|3 months ago|reply
[+] [-] meander_water|3 months ago|reply
I don't think urls were built for that kind of punishment.
[+] [-] ooxoo|3 months ago|reply
[+] [-] medv|3 months ago|reply
- https://textarea.my/#TYuxDcIwEEWpmeKUCiSIJQoKU0KFRBUWOGwnWDi...
[+] [-] greggman65|3 months ago|reply
If you click save you get the option to use a URL.
The problem with a URL every edit is a new URL. So you send the URL to a friend, then fix a typo, they need a new URL.
The other problem is of course the space limit.
[+] [-] wwarren|3 months ago|reply
[+] [-] codazoda|3 months ago|reply
I built Ponder in the same vein. It, however, has 10 files. I did not use the URL, did not have double the fun, and now I’m sad.
https://github.com/codazoda/ponder
[+] [-] marcuskaz|3 months ago|reply