Simon Willison’s Weblog

Newsletter

Saturday, 17th October 2026

web-edit (previously) is my tiny web app for browsing and editing files in a folder. I mainly built it for editing files on different machines via Tailscale.

I added a "copy to clipboard" option for both text and image data. I needed this because I was running pelican prompts on a laptop from my phone (here's DeepSeek 4.1 Flash 1017) and I wanted an easy way to copy the resulting logs into a Gist.

Sighting 2:07 PM – 2:12 PM — House Sparrow, Eastern Gray Squirrel, in Philadelphia Center City, PA, US
House Sparrow
House Sparrow
Eastern Gray Squirrel
Eastern Gray Squirrel

Inline rendering with document​.currentScript. Lean Rada describes a neat trick that takes advantage of the document.currentScript property. You can use that to drop in a tiny inline <script> element that replaces itself when the page loads:

The year is <script>
document.currentScript.replaceWith(
  new Date().getFullYear())</script>

If you define a shortcut function like this:

$=(...n)=>document.currentScript.replaceWith(...n)

You get a tiny template language:

The year is <script>$(new Date().getFullYear())</script>

# 9:11 pm / javascript

← Friday, 16th October 2026

2026 » October

MTWTFSS
   1234
567891011
12131415161718
19202122232425
262728293031