1import { fetch } from "https://esm.town/v/std/fetch";
2
3export async function fetchGHRepoInfo(userName, repoName) {
4 const response = await fetch(`https://ungh.cc/repos/${userName}/${repoName}`);
5 return await response.json();
6}
1// fetch("https://api.val.town/v1/express/ramkarthik.GenerateQR?url={url}"
2export async function GenerateQR(req, res) {
3 const url = req.query.url;
1import { fetch } from "https://esm.town/v/std/fetch";
2
3export const weather = async (city: string): Promise<unknown> => {
4 let data = await fetch(`https://wttr.in/${city}?format=j1`);
5 return data.json();
6};
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// GitHub starred repos
4export let githubStarred = fetchJSON(
5 "https://api.github.com/users/stevekrouse/starred"
6);
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// GitHub starred repos
4export let githubStarred = fetchJSON("https://api.github.com/users/potherca/starred")
5 .then((repos) => repos.map((repo) => repo.html_url));
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export let testcase1 = fetchJSON('https://api.val.town/eval/@stevekrouse.example1')
4
1import { fetch } from "https://esm.town/v/std/fetch";
2import { REACT_DOM_MINIFIED } from "https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED";
3let { REACT_DOM_MINIFIED_PT4 } = await import("https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED_PT4");
7
8export async function buildReactDomMinified() {
9 const res = await fetch(
10 "https://unpkg.com/react-dom@18.2.0/umd/react-dom.production.min.js",
11 );
1import { fetch } from "https://esm.town/v/std/fetch";
2
3let { REACT_MINIFIED } = await import("https://esm.town/v/liamdanielduffy/REACT_MINIFIED");
4
5export async function buildReactMinified() {
6 let res = await fetch(
7 "https://unpkg.com/react@18/umd/react.production.min.js",
8 );
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// GitHub gists
4export let githubGists = fetchJSON(
5 "https://api.github.com/users/stevekrouse/gists"
6);
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// GitHub followers
4export let githubFollowers = fetchJSON(
5 "https://api.github.com/users/stevekrouse/followers"
6);