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/$%7Bart_info.art.src%7D?q=function&page=1735&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 17976 results for "function"(1573ms)

myApimain.tsx1 match

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

fetchValTownAPImain.tsx1 match

@pomdtr•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export async function fetchValTownAPI(
4 apiToken: string,
5 path: string,

untitled2342187main.tsx1 match

@byrneml•Updated 1 year ago
8}
9
10export async function giveMeLeNews({ feedlyAPI }: LeNews) {
11 return "Works";
12}

patronummain.tsx1 match

@effector•Updated 1 year ago
1export async function patronum() {
2 const patronum = await import("https://esm.sh/patronum@1.19.1");
3 return patronum;

myApimain.tsx1 match

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

nullifymain.tsx1 match

@eric•Updated 1 year ago
1let { definitelynotnull } = await import("https://esm.town/v/eric/definitelynotnull");
2
3export function nullify() {
4 definitelynotnull = null
5}

myApimain.tsx1 match

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

getMunichSwimCapacitmain.tsx4 matches

@fgeierst•Updated 1 year ago
1import { fetch } from "https://esm.town/v/std/fetch";
2
3export async function getMunichSwimCapacit() {
4 const organizationUnitIds = [
5 { id: 30182, name: "Olympia-Schwimmhalle" },
21 { id: 30200, name: "Dantebad Sauna" },
22 ];
23 async function fetchCount(id) {
24 const endpoint =
25 `https://functions.api.ticos-systems.cloud/api/gates/counter?organizationUnitIds=${id}`;
26 const response = await fetch(endpoint, {
27 headers: {
49 return { id, personCount, maxPersonCount };
50 }
51 async function populateUnits() {
52 for (let unit of organizationUnitIds) {
53 const populatedUnit = await fetchCount(unit.id);

updateTicketCoordinatormain.tsx1 match

@ytf•Updated 1 year ago
1import process from "node:process";
2
3export async function updateTicketCoordinator() {
4 // read user profiles and fint those who want to be a tickets master and add those to group @tickets-coordinators
5 // Require the Node Slack SDK package (github.com/slackapi/node-slack-sdk)

myApimain.tsx1 match

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

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": "*",