oldDebugging_Guidemain.tsx1 match
484950Using your intuition as a starting point. Did you change a function recently? Are there any likely culprits?
5152
WobbleShapesmain.tsx4 matches
3import { createRoot } from "https://esm.sh/react-dom/client";
45function PotteryPlate({ radius, color, wobbliness, wobbleFrequency, wobbleIrregularity, rotation }) {
6const points = [];
7const centerX = 250;
35}
3637function App() {
38const [plate, setPlate] = useState(null);
39const [svgString, setSvgString] = useState('');
139}
140141function client() {
142createRoot(document.getElementById("root")).render(<App />);
143}
144if (typeof document !== "undefined") { client(); }
145146async function server(request: Request): Promise<Response> {
147return new Response(`
148<!DOCTYPE html>
primeTurquoiseTernmain.tsx1 match
2import { easyAQI } from "https://esm.town/v/stevekrouse/easyAQI?v=5";
34export async function aqi(interval: Interval) {
5const location = "40509"; // <-- change to place, city, or zip code
6const data = await easyAQI({ location });
dateme_browsemain.tsx4 matches
5import { zip } from "npm:lodash-es";
67function absoluteURL(url) {
8if (url.startsWith("http://") || url.startsWith("https://"))
9return url;
25let linkClass = "text-sky-600 hover:text-sky-500";
2627function httpsIfy(url: string) {
28if (!url.startsWith("http://") && !url.startsWith("https://")) {
29return `https://${url}`;
32}
3334function renderCell(header, row) {
35let data = row[header];
36if (header === "Name") {
46}
4748export default async function Browse(c) {
49const url = new URL(c.req.url);
50const search = {
passwordGenmain.tsx4 matches
3import { createRoot } from "https://esm.sh/react-dom/client";
45function App() {
6const [darkMode, setDarkMode] = useState(false);
7const [input, setInput] = useState("");
200}
201202function client() {
203createRoot(document.getElementById("root")).render(<App />);
204}
208}
209210async function server(request: Request): Promise<Response> {
211if (request.method === "POST" && new URL(request.url).pathname === "/generate") {
212const { input, policy } = await request.json();
270}
271272function generatePasswords(input: string, policy: any): string[] {
273const substitutions = [
274{ original: "i", replacements: ["1", "!"] },
dateme_browsemain.tsx4 matches
5import { zip } from "npm:lodash-es";
67function absoluteURL(url) {
8if (url.startsWith("http://") || url.startsWith("https://"))
9return url;
25let linkClass = "text-sky-600 hover:text-sky-500";
2627function httpsIfy(url: string) {
28if (!url.startsWith("http://") && !url.startsWith("https://")) {
29return `https://${url}`;
32}
3334function renderCell(header, row) {
35let data = row[header];
36if (header === "Name") {
46}
4748export default async function Browse(c) {
49const url = new URL(c.req.url);
50const search = {
extractSchemaOrgJsonmain.tsx1 match
1import { DOMParser } from "https://esm.sh/linkedom";
23export default async function server(request: Request): Promise<Response> {
4if (request.method !== "GET") {
5return new Response("Method not allowed", { status: 405 });
10```
1112* Export any "global" p5 functions. These are functions like `setup` and `draw` that p5 will call.
1314* Set the val type to http and default export the result of `sketch`, passing in `import.meta.url`.
19import type * as p5 from "npm:@types/p5";
2021export function setup() {
22createCanvas(400, 400);
23}
2425export function draw() {
26if (mouseIsPressed) {
27fill(0);
3738## How it works
39The sketch function returns an http handler that sets up a basic page with p5.js added. It then imports your module from the browser and wires up all the exports so p5.js can see them. All the code in your val will run in the browser (except for the default `sketch` export) so you can't call any Deno functions, environment variables, or other server side apis.
40
1export function sketch(module: string): (req: Request) => Response {
2return function(req: Request): Response {
3return new Response(
4`
40}
4142export default async function(req: Request): Promise<Response> {
43return new Response(
44`
add_to_notion_w_aimain.tsx9 matches
35});
3637function createPrompt(title, description, properties) {
38let prompt =
39"You are processing content into a database. Based on the title of the database, its properties, their types and options, and any existing descriptions, infer appropriate values for the fields:\n";
80}
8182function processProperties(jsonObject) {
83const properties = jsonObject.properties;
84const filteredProps = {};
111}
112113async function get_and_save_notion_db_processed_properties(databaseId)
114{
115const response = await notion.databases.retrieve({ database_id: databaseId });
122}
123124async function get_notion_db_info(databaseId) {
125databaseId = databaseId.replaceAll("-", "");
126let db_info = null;
137}
138139async function get_and_save_notion_db_info(databaseId) {
140databaseId = databaseId.replaceAll("-", "");
141let db_info = await get_and_save_notion_db_processed_properties(databaseId);
144}
145146function createZodSchema(filteredProps) {
147const schemaObject = {};
148193}
194195function convertToNotionProperties(responseValues, filteredProps) {
196const notionProperties = {};
197268}
269270async function process_text(dbid, text) {
271const db_info = await get_notion_db_info(dbid);
272const processed_message = await client.chat.completions.create({
283}
284285async function addToNotion(databaseId, text) {
286databaseId = databaseId.replaceAll("-", "");
287const properties = await process_text(databaseId, text);