LangChain (https://langchain.com) Ambassador, KubeSphere (https://kubesphere.io) Ambassador, CNCF OpenFunction (https://openfunction.dev) TOC Member.
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": "*",
1export default async function(req: Request): Promise<Response> {
2 const html = `
3 <!DOCTYPE html>
71 let computerScore = 0;
72
73 function play(playerChoice) {
74 const choices = ['rock', 'paper', 'scissors'];
75 const computerChoice = choices[Math.floor(Math.random() * 3)];
3import { Header } from "./Header.tsx";
4
5export function LayoutRoute () {
6 // TODO fetch here because we're not doing any caching
7 // and we want the user data in the header ?
A helper function to build a file's email
Simple functional CSS library for Val Town