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/$%7Bsuccess?q=function&page=1794&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 18135 results for "function"(2959ms)

parseXMLmain.tsx1 match

@stevekrouse•Updated 1 year ago
1export async function parseXML(xml) {
2 const { XMLParser } = await import("https://esm.sh/fast-xml-parser@4.1.2");
3 const parser = new XMLParser();

hnFollowPollJobmain.tsx1 match

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

myExpressApimain.tsx1 match

@stevekrouse•Updated 1 year ago
2import { set } from "https://esm.town/v/std/set?v=11";
3
4export async function myExpressApi(req: express.Request, res: express.Response) {
5 res.json({
6 count: await set(

fetchCongressTradeReportsmain.tsx1 match

@stevekrouse•Updated 1 year ago
2import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
3
4export async function fetchCongressTradeReports({ lastRunAt }) {
5 const res = await fetchJSON(
6 "https://bff.capitoltrades.com/trades?sortBy=-pubDate",

myApimain.tsx1 match

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

myApimain.tsx1 match

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

FunctionToHTMLFormmain.tsx4 matches

@rodrigotello•Updated 1 year ago
1import { valForm } from "https://esm.town/v/rodrigotello/valForm";
2import { multiplicationFunctionTest } from "https://esm.town/v/rodrigotello/multiplicationFunctionTest";
3
4export async function FunctionToHTMLForm(
5 req: express.Request,
6 res: express.Response,
7) {
8 let myFunctionValAsHTML = multiplicationFunctionTest; // Insert your function here and it should generate an HTML form
9 return res.send(`${valForm(myFunctionValAsHTML)}`);
10}

timeAgomain.tsx1 match

@rodrigotello•Updated 1 year ago
1export async function timeAgo(date: Date) {
2 const { timeAgo } = await import("https://deno.land/x/time_ago/mod.ts");
3 return timeAgo(new Date(date));

vtInspoHTMLmain.tsx1 match

@rodrigotello•Updated 1 year ago
1import { valTownInspoList } from "https://esm.town/v/rodrigotello/valTownInspoList";
2
3export function vtInspoHTML(req, res) {
4 res.send(
5 valTownInspoList.map((valTownInspo) =>

valTownDailyInspomain.tsx1 match

@rodrigotello•Updated 1 year ago
1import { valTownInspirationEmail } from "https://esm.town/v/rodrigotello/valTownInspirationEmail";
2
3export async function valTownDailyInspo() {
4 return await valTownInspirationEmail();
5}

getFileEmail4 file matches

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

tuna8 file matches

@jxnblk•Updated 2 weeks 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": "*",