Avatar

peterqliu

peterqliu.github.io
Joined January 28, 2023
Public vals
6
peterqliu avatar
peterqliu
selfDestruct
Script
💥 Deletes the val using it, or whatever url is fed it. Handy for sharing single-use scripts without cluttering people's accounts. If used in an HTTP val, this will run immediately when anyone forks it, making for a zero-click execution as long as ValTown immediately serves a preview of the forked val. Add this to your code last and then do not run it, or you will lose your work. Recommend first checking that the val owner isn't you, so that only forked copies will self-destruct. Usage selfDestruct(import.meta.url) Returns a promise of successful deletion, though the val would not be around to read it.
3
peterqliu avatar
peterqliu
vt_app_v3
HTTP
@jsxImportSource https://esm.sh/hono@4.0.8/jsx
0
peterqliu avatar
peterqliu
vt_app
HTTP
@jsxImportSource https://esm.sh/hono@4.0.8/jsx
0
peterqliu avatar
peterqliu
dbInit
Script
// run this just once
0
peterqliu avatar
peterqliu
TokenDB
Script
// modify these as necessary. these can change safely without breakage,
0
peterqliu avatar
peterqliu
generateString
Script
An interactive, runnable TypeScript val by peterqliu
0
Next