1
2
3
4
5
6
7
8
import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
// accessible via API at https://api.val.town/eval/@stevekrouse.basicAPIEx
export const basicAPIEx = fetchJSON(
"https://date.nager.at/api/v2/publicholidays/2023/US"
);
// Bonus: the whole runtime is available in the URL Bar 🤯
// ie https://api.val.town/eval/"The first holiday is "+ @stevekrouse.basicAPIEx[0].name
Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
v4
October 23, 2023