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/$%7Burl%7D?q=function&page=2388&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 28957 results for "function"(1837ms)

industriousEmeraldWhippetmain.tsx1 match

@sheepish•Updated 6 months ago
2
3// Fetches a random joke.
4async function fetchRandomJoke() {
5 const response = await fetch(
6 "https://official-joke-api.appspot.com/random_joke",

jokeGeneratorValmain.tsx1 match

@naomizhang•Updated 6 months ago
2
3// Fetches a random joke.
4async function fetchRandomJoke() {
5 const response = await fetch(
6 "https://official-joke-api.appspot.com/random_joke",

harmoniousBlackStoatmain.tsx1 match

@eddietheegg2•Updated 6 months ago
2
3// Fetches a random joke.
4function fetchRandomJoke() {
5 const response = fetch(
6 "https://official-joke-api.appspot.com/random_joke",

labLoginUpdateStatusmain.tsx1 match

@gaimeri17•Updated 6 months ago
3import { sqlite } from "https://esm.town/v/std/sqlite";
4
5export default async function(req: Request): Promise<Response> {
6 const TABLE_NAME = "lab_login_users_with_times";
7 const body = await req.json();

labLoginDeleteAccountmain.tsx1 match

@gaimeri17•Updated 6 months ago
2import { sqlite } from "https://esm.town/v/std/sqlite";
3
4export default async function(req: Request): Promise<Response> {
5 const TABLE_NAME = "lab_login_users_with_times";
6 const body = await req.json();

labLoginBanUsermain.tsx1 match

@gaimeri17•Updated 6 months ago
2import { sqlite } from "https://esm.town/v/std/sqlite";
3
4export default async function(req: Request): Promise<Response> {
5 const TABLE_NAME = "lab_login_users_with_times";
6 const body = await req.json();

labLoginGetUsersmain.tsx1 match

@gaimeri17•Updated 6 months ago
2import { sqlite } from "https://esm.town/v/std/sqlite";
3
4export default async function(req: Request): Promise<Response> {
5 const TABLE_NAME = "lab_login_users_with_times";
6

api_v1main.tsx2 matches

@maxharper26•Updated 6 months ago
1import { Client } from "https://deno.land/x/postgres@v0.17.0/mod.ts";
2
3// Define the HTTP val function
4export default async function fetchReturns(request: Request): Promise<Response> {
5 const databaseUrl = Deno.env.get("db_key_val_format");
6 if (!databaseUrl) {

stirringVioletHookwormmain.tsx1 match

@ryan_alive•Updated 6 months ago
30}
31
32export default async function aliveEvidenceSearchAlert({ lastRunAt }: Interval) {
33 console.log("Starting Alive Evidence search alert...");
34

twitterAlertmain.tsx1 match

@ryan_alive•Updated 6 months ago
4const query = "\"val.town\" OR \"val.run\" OR \"val town\" -_ValTown_ -is:retweet -from:valenzuelacity -from:val__run";
5
6export async function twitterAlert({ lastRunAt }: Interval) {
7 // search
8 // const since = Math.floor((Date.now() / 1000) - (24 * 60 * 60)); // test since for last day
tuna

tuna9 file matches

@jxnblk•Updated 18 hours ago
Simple functional CSS library for Val Town

getFileEmail4 file matches

@shouser•Updated 1 month ago
A helper function to build a file's email
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": "*",
webup
LangChain (https://langchain.com) Ambassador, KubeSphere (https://kubesphere.io) Ambassador, CNCF OpenFunction (https://openfunction.dev) TOC Member.