mockingSpongebobmain.tsx2 matches
1/**
2* Function that randomly capitalizes or lowercases each character in a string.
3* Inspired by the mocking Spongebob meme: https://knowyourmeme.com/memes/mocking-spongebob
4*
8* @param text The text to be transformed
9*/
10export default function mockingSpongebob(text: string) {
11let result = "";
12for (let i = 0; i < text.length; i++) {
redSpoonbillmain.tsx1 match
1export async function getTopTenBattingAverage() {
2const data = await fetch(
3"http://sports.core.api.espn.com/v2/sports/baseball/leagues/mlb/seasons/2024/types/2/leaders?lang=en®ion=us",
EditLinkModalmain.tsx1 match
3import { jsx, Fragment } from 'https://deno.land/x/hono/middleware.ts'
45export default function EditLinkModal({ username, linkId, label, url }) {
6
7return (
ctanPackageNamesmain.tsx1 match
1export default async function(req: Request): Promise<Response> {
2const response = await fetch("https://ctan.org/json/2.0/packages");
3const packages = await response.json();
googleFeelingLuckymain.tsx6 matches
5"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36";
67export default async function(req: Request): Promise<Response> {
8const { searchParams } = new URL(req.url);
9const query = searchParams.get("q");
17}
1819export function search(query: string, userAgent = DEFAULT_USER_AGENT) {
20const searchUrl = createSearchUrl(query);
21return getRedirectUrl(searchUrl, userAgent);
22}
2324export function createSearchUrl(query: string, buttonName = "") {
25const searchURL = new URL("https://www.google.com/search");
26searchURL.searchParams.set("q", query);
29}
3031export async function getRedirectUrl(searchUrl: string | URL, userAgent = DEFAULT_USER_AGENT) {
32const resp = await ky.get(searchUrl, { headers: { "user-agent": userAgent } });
33const { searchParams } = new URL(resp.url);
36}
3738export async function signSearchUrl(searchUrl: string | URL) {
39const signedURL = new URL(searchUrl);
40const params = await getSearchParams();
43}
4445export async function getSearchParams(userAgent = DEFAULT_USER_AGENT) {
46await initParser();
47const html = await ky.get("https://www.google.com", { headers: { "user-agent": userAgent } }).text();
fetchWorkermain.tsx2 matches
6workerURL.searchParams.set("worker", "1");
78export async function fetchWorker(opts: {
9url: string;
10handler?: string;
83}
8485export function setupWorker() {
86let handler: (req: Request) => Promise<Response>;
87
userAgentsmain.tsx1 match
102];
103104export function getRandomUserAgent() {
105const i = Math.floor(Math.random() * USER_AGENTS.length);
106return USER_AGENTS[i];
9});
1011export default async function handler(request: Request) {
12if (request.method !== "POST") {
13return html(`
magentaMarlinmain.tsx1 match
2import { set } from "https://esm.town/v/std/set?v=11";
34export async function signGuestBook(message) {
5guestBook.unshift(message);
6await set("guestBook", guestBook);