Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/?q=function&page=1673&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=function

Returns an array of strings in format "username" or "username/projectName"

Found 17342 results for "function"(2799ms)

myApimain.tsx1 match

@tannerwj•Updated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

myApimain.tsx1 match

@evilpaper•Updated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

myApimain.tsx1 match

@dereko•Updated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

webhookTestmain.tsx1 match

@markprobst•Updated 1 year ago
1import { decomposeGlideWebhookParams } from "https://esm.town/v/markprobst/decomposeGlideWebhookParams";
2
3export async function webhookTest(params) {
4 const [name, stock] = await decomposeGlideWebhookParams(
5 params,

hnFollowPollJobErrormain.tsx1 match

@stevekrouse•Updated 1 year ago
3import { hnLatestPosts } from "https://esm.town/v/stevekrouse/hnLatestPosts";
4
5export async function hnFollowPollJobError({ lastRunAt }: Interval) {
6 try {
7 let posts = await hnLatestPosts({

pollRSSFeedsmain.tsx1 match

@tmcw•Updated 1 year ago
1import { newRSSItems } from "https://esm.town/v/stevekrouse/newRSSItems?v=6";
2
3export async function pollRSSFeeds() {
4 return Object.entries({
5 mine: "https://macwright.com/rss.xml",

exampleAuthApimain.tsx1 match

@stevekrouse•Updated 1 year ago
3import { verifyAPIAuth } from "https://esm.town/v/stevekrouse/verifyAPIAuth";
4
5export async function exampleAuthApi(arg1, arg2, auth) {
6 let { handle } = await verifyAPIAuth(auth);
7 if (handle) {

alivemain.tsx1 match

@stevekrouse•Updated 1 year ago
1import { wikidata } from "https://esm.town/v/stevekrouse/wikidata";
2
3export async function alive(name) {
4 let data = await wikidata(
5 `SELECT ?person ?personLabel ?birth_date ?death_date WHERE {

nominatimSearchmain.tsx1 match

@stevekrouse•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
2
3export function nominatimSearch(params: Search): Promise<Place[]> {
4 return fetchJSON(
5 "https://nominatim.openstreetmap.org/search?" +

pixelmain.tsx2 matches

@stevekrouse•Updated 1 year ago
2import { pixelData } from "https://esm.town/v/stevekrouse/pixelData";
3
4export async function pixel(req: express.Request, res: express.Response) {
5 if (req.path === "/") {
6 let html = `
23 let img = document.getElementsByTagName("img")[0]
24 let input = document.getElementsByTagName("input")[0]
25 input.addEventListener('input', function(e){
26 img.src="/track?id=" + e.target.value
27 })

getFileEmail4 file matches

@shouser•Updated 1 week ago
A helper function to build a file's email
tuna

tuna8 file matches

@jxnblk•Updated 1 week ago
Simple functional CSS library for Val Town
webup
LangChain (https://langchain.com) Ambassador, KubeSphere (https://kubesphere.io) Ambassador, CNCF OpenFunction (https://openfunction.dev) TOC Member.
lost1991
import { OpenAI } from "https://esm.town/v/std/openai"; export default async function(req: Request): Promise<Response> { if (req.method === "OPTIONS") { return new Response(null, { headers: { "Access-Control-Allow-Origin": "*",