Using Tesseract.js to OCR every image on a page
Pasting this code into a DevTools console should load Tesseract.js from a CDN, loop through every image loaded by that page (every PNG, GIF, JPG or JPEG), run OCR on them and output the result to the…
37 posts tagged “javascript”.
Pasting this code into a DevTools console should load Tesseract.js from a CDN, loop through every image loaded by that page (every PNG, GIF, JPG or JPEG), run OCR on them and output the result to the…
Purple Air sensors have an API at , which returns JSON that looks something like this: There's just one problem with this: it doesn't give you the AQI number that is displayed on their site!
Lit 2 stable was released today, offering a tiny, feature-full framework for constructing web components using modern JavaScript.
If you copy and paste from a web page - including a full table - into a GitHub issue comment GitHub converts it to the corresponding Markdown for you. Really quick way to construct Markdown tables.
A few notes on JavaScript object, based on trying to do some basic things with them in Observable notebooks.
The EC2 pricing page shows cost per hour, which is pretty much useless. I want cost per month. The following JavaScript, pasted into the browser developer console, modifies the page to show…
For a Django application I'm working on (this issue) I have a form that can be quite a long way down the page.
A Datasette feature suggestion concerning autocomplete against a list of known values inspired me to learn how to use the HTML element (see MDN).
Deno Deploy is a hosted Deno service that promises a multi-tenant JavaScript engine running in 25 data centers across the world.
My tools.simonwillison.net site is a growing collection of small HTML and JavaScript applications hosted as static files on GitHub Pages.
Given an array of datetime objects, I wanted to plot a histogram. But I wanted to automatically pick a bucket size for that histogram that resulted in something interesting, no matter what range of…
Initial article: April 28th 2023 - see below for an update I got intrigued by Deno KV, which describes itself as "a global database for global apps".
JSR is a brand new package repository for "modern JavaScript and TypeScript", launched on March 1st by the Deno team as a new alternative to npm My JavaScript ecosystem fluency isn't great, so it took…
TikTok may or may not be banned in the USA within the next 24 hours or so. Here's a pattern you can use to download all of the videos from a specific account.
Jake Archibald pointed to his for as a "modernish example" of NPM packaging on Twitter this morning. I've been frustrated at my lack of understanding of for too long, so I decided to do some research…
I needed this for VIAL issue 722. I decided to disable form submissions for two seconds after they are submitted, to protect against accidental double submissions without risk of unexpected issues…
This is almost really simple. I used electron/update-electron-app for it, the instructions for which are: - Add it to with - Make sure your field in that file points to your GitHub repository - Use…