![neverstew avatar](https://secure.gravatar.com/avatar/109fa713caf4e083c57622b7c6dad365.jpg?s=200&d=identicon)
neverstew
blobDirList
Script
List things in a blob directory Blobs can be organised using "directories" e.g. /animals
all-animals.txt
/dogs
sausage.txt
/cats
tom.txt is really only three files: /animals/all-animals.txt , /animals/dogs/sausage.txt and /animals/cats/tom.txt because directories don't really exist, we're just making longer filenames. When you want to list things only "in a directory" and none of the child "directories", you can use this val. import { blobDirList } from "https://esm.town/v/neverstew/blobDirList";
console.log(await blobDirList("/animals"));
// returns only "/animals/all-animals.txt"
2
jdan
basicAuthButton
HTTP
basicAuthButton An authenticated micro-app for tracking the last time I took a medication. Both GET / and POST /press are authenticated using honoBasicAuthMiddleware . GET / Views the value of basicAuthButton:last-pressed in blob storage. POST /press Updates the value of basicAuthButton:last-pressed in blob storage with the current timestamp.
1
Updated: August 13, 2024