Avatar

vladimyr

Joined August 5, 2023
Likes
94
pomdtr avatar
extractImports
@pomdtr
Script
An interactive, runnable TypeScript val by pomdtr
pomdtr avatar
cdn
@pomdtr
HTTP (deprecated)
Val Town CDN If you only want to get the source of a val, you should use https://esm.town/ instead. Usage curl https://pomdtr-cdn.web.val.run/<author>/<name>.<extension>[?v=<version>] To see the code of this val, use https://pomdtr-cdn.web.val.run/pomdtr/cdn.ts Examples Fetching the val code $ curl https://pomdtr-cdn.web.val.run/pomdtr/add.tsx You can also use js , jsx and ts extension (only the content-type change, there is no transpilation). Fetching private val Pass an api token as an username $ curl "https://<token>@pomdtr-cdn.web.val.run/pomdtr/privateVal.ts" Fetching the val README $ curl https://pomdtr-cdn.web.val.run/pomdtr/add.md Getting an image $ curl https://pomdtr-cdn.web.val.run/pomdtr/add.png Fetching a specific version of a val $ curl https://pomdtr-cdn.web.val.run/pomdtr/cdn.ts?v=66 You need to be authenticated to use this method. Fetching the val metadata $ curl https://pomdtr-cdn.web.val.run/pomdtr/add.json
postpostscript avatar
sqliteBlob
@postpostscript
Script
sqliteBlob: make sqlite queries against your blobs!* does not include blob values
postpostscript avatar
sqliteUniverse
@postpostscript
Script
sqliteUniverse: make queries against multiple vals or endpoints at the same time! Example: @postpostscript/sqliteUniverseExample Todo [ ] tests‼️ [ ] update to support following syntax: SELECT * FROM "@example/endpoint".someTable or SELECT * FROM "@example/endpoint:::someTable"
postpostscript avatar
sqliteUniverseExample
@postpostscript
Script
An interactive, runnable TypeScript val by postpostscript
postpostscript avatar
sqlitePublic
@postpostscript
HTTP (deprecated)
An interactive, runnable TypeScript val by postpostscript
easrng avatar
playground
@easrng
HTTP (deprecated)
playground edit, run, and embed vals without requiring an account (or even js enabled!) caveats: logs don't stream I haven't set up codemirror only script vals supported everything else should be fully functional. you can prefill the editor with code: https://easrng-playground.web.val.run/?code=console.log(1) a val: https://easrng-playground.web.val.run/?load=easrng/playground some other url: https://easrng-playground.web.val.run/?load=https://any/other/url
postpostscript avatar
MyFooter
@postpostscript
HTTP (deprecated)
@postpostscript/MyFooter: my footer component which shares random vals I've liked!
postpostscript avatar
recommends
@postpostscript
Script
An interactive, runnable TypeScript val by postpostscript
postpostscript avatar
valTownLogo
@postpostscript
Script
// let me know if this is an issue :)
nbbaier avatar
emptyValUtils
@nbbaier
Script
Empty Val Utils Handy utility functions to see if you have vals with no code lying around your account and to delete them (is you want to). Usage listEmptyVals import {listEmptyVals } from "https://esm.town/v/nbbaier/deleteEmptyVals"; console.log(await listEmptyVals(<user_id>)) deleteEmptyVals import {listEmptyVals } from "https://esm.town/v/nbbaier/deleteEmptyVals"; await deleteEmptyVals(<user_id>)
agmm avatar
teapot
@agmm
HTTP (deprecated)
An interactive, runnable TypeScript val by agmm
andreterron avatar
codeOnVT_ribbonElement
@andreterron
Script
"Code on Val Town" Ribbon HTML Element Ribbon element used by @andreterron/codeOnValTown Usage ribbonElement({val: { handle: "andre", name: "foo" }}) - define which val to link to; ribbonElement() - infer the val from the call stack. Example: @andreterron/openable_element import { ribbonElement } from "https://esm.town/v/andreterron/codeOnVT_ribbonElement?v=3"; import { html } from "https://esm.town/v/stevekrouse/html?v=5"; export default async (req: Request): Promise<Response> => { return html(` <h2>Hello world!</h2> <style>* { font-family: sans-serif }</style> ${ribbonElement()} `); };
postpostscript avatar
hash
@postpostscript
Script
An interactive, runnable TypeScript val by postpostscript
pomdtr avatar
todo
@pomdtr
HTTP (deprecated)
All TODOs from public vals Todo [ ] Remove forks from results ? [ ] use a cron val to cache results in an sqlite table
postpostscript avatar
moduleHighlightValueLink
@postpostscript
HTTP (deprecated)
moduleHighlightValueLink: Link to a Val With a Value or Method's Code Highlighted Examples: import { moduleHighlightValueLink, getRedirectUrl } from "https://esm.town/v/postpostscript/moduleHighlightValueLink"; console.log(await moduleHighlightValueLink("@std/email", "email")) // https://val.town/v/std/email#L6-42 console.log(await moduleHighlightValueLink("@postpostscript/moduleHighlightValueLink", "moduleHighlightValueLink")) // https://val.town/v/postpostscript/moduleHighlightValueLink#L6-20 // get URL you can imbed in an iframe console.log(getRedirectUrl("@postpostscript/moduleHighlightValueLink", "getRedirectUrl", true)); // https://postpostscript-modulehighlightvaluelink.web.val.run/?embed=1&module=%40postpostscript%2FmoduleHighlightValueLink&name=getRedirectUrl Iframe example: import { htmlResponse } from "https://esm.town/v/postpostscript/html"; import { getRedirectUrl } from "https://esm.town/v/postpostscript/moduleHighlightValueLink"; export default async function(req: Request): Promise<Response> { return htmlResponse` <iframe src="${getRedirectUrl(import.meta.url, "default", true)}" width="100%" height="100%"> </iframe> `; }