Search

Results include substring matches and semantically similar vals. Learn more
temptemp avatar
workers
@temptemp
@jsxImportSource npm:hono/jsx
HTTP
/** @jsxImportSource npm:hono/jsx */
const commonHeaders = {
"accept": "*/*",
"accept-language": "en-US,en;q=0.9",
"user-agent": faker.internet.userAgent(),
"priority": "u=4, i",
"sec-ch-ua": "\"Not)A;Brand\";v=\"99\", \"Google Chrome\";v=\"127\", \"Chromium\";v=\"127\"",
"sec-ch-ua-mobile": "?0",
"sec-ch-ua-platform": "\"Windows\"",
"sec-fetch-dest": "empty",
u avatar
site
@u
An interactive, runnable TypeScript val by u
Script
export let site = (req: express.Request, res: express.Response) => {
res.set("Content-Type", "text/html");
res.send(`<!DOCTYPE html>
<html lang="en" class="sl-theme-dark">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
temptemp avatar
transcendentTanToucan
@temptemp
An interactive, runnable TypeScript val by temptemp
Cron
const script = `
export default {
async fetch(request, env, ctx) {
const cacheUrl = decodeURIComponent(new URL(request.url).searchParams.get("url"));
const cacheKey = new Request(cacheUrl.toString(),request);
const cache = caches.default;
let response = await cache.match(cacheKey);
if (!response) {
console.log("Cacheing :" ,cacheKey.url);
response = await fetch(cacheKey);
willthereader avatar
personalWebsite
@willthereader
@jsxImportSource https://esm.sh/hono@latest/jsx
HTTP
/** @jsxImportSource https://esm.sh/hono@latest/jsx **/
const app = new Hono();
// Add a middleware to include the viewport meta tag and additional CSS in all HTML responses
app.use("*", async (c, next) => {
await next();
if (c.res.headers.get("Content-Type")?.includes("text/html")) {
const html = await c.res.text();
const updatedHtml = html.replace(
"</head>",
<meta name="viewport" content="width=device-width, initial-scale=1.0">
nxtlvlmike avatar
sharpAmberVulture
@nxtlvlmike
// [Previous code remains the same]
HTTP
// [Previous code remains the same]
export default async function server(request: Request): Promise<Response> {
const css = `
:root {
--primary-color: #6a11cb;
--secondary-color: #2575fc;
--background-color: #f4f6f9;
--text-color: #333;
--card-background: white;
--accent-color: #4CAF50;
dhvanil avatar
web_XbaTV2IAS1
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function web_XbaTV2IAS1(req) {
return new Response(`<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Cyber Future 3000</title>
<style>
body {
margin: 0;
temptemp avatar
rabbitstream
@temptemp
// Full .ts implimentation of rabbitstream.net
HTTP
// Full .ts implimentation of rabbitstream.net
// Author : cool-dev-guy@github.com (cool-dev-guy)
// About : A one-file easy-deploy .ts code(specifically made for deno). for quick deployments.
// Thanks to :
// - ciarands@github.com (ciarands) [for payload script to extract variables]
// - drbgln@github.com (drbgln) [for reference script fordecryption]
const app = new Hono();
app.get("/:provider/:id", async (c) => {
try {
const { provider, id } = c.req.param();
dhvanil avatar
web_J0B5T4JyqD
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function web_J0B5T4JyqD(req) {
return new Response(`<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Modern Neon Design</title>
<style>
body {
margin: 0;
dhvanil avatar
web_uecrPCN6rT
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function web_uecrPCN6rT(req) {
return new Response(`<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Cyberpunk Retro-Wave</title>
<style>
body {
margin: 0;
dhvanil avatar
web_6WlNAlBG2k
@dhvanil
An interactive, runnable TypeScript val by dhvanil
HTTP
export async function web_6WlNAlBG2k(req) {
return new Response(`<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Dynamic Neon Website</title>
<style>
body {
margin: 0;
stainless_em avatar
openapi_playground
@stainless_em
openapi playground temporarily host swagger and prism for your openapi spec
HTTP
# openapi playground
temporarily host swagger and prism for your openapi spec
/** @jsx jsx */
/** @jsxFrag Fragment */
createContext,
type FC,
Fragment,
jsx,
type PropsWithChildren,
useContext,
jonbo avatar
nearbyJonBo
@jonbo
// Forked from @tmcw.big_story_visualization
Script
export let nearbyJonBo = async (req, res) => {
const { default: htm } = await import("npm:htm");
const { default: vhtml } = await import("npm:vhtml");
const html = htm.bind(vhtml);
const raw = (html) =>
vhtml(null, {
dangerouslySetInnerHTML: { __html: html },
res.send(html`
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" style="display: grid; height: 100vh">
tempdev avatar
compactBlushGrasshopper
@tempdev
An interactive, runnable TypeScript val by tempdev
Script
const BASEDOM = "https://whisperingauroras.com";
interface Servers {
name: string | null;
dataHash: string | null;
interface APIResponse {
name: string | null;
image: string | null;
mediaId: string | null;
stream: string | null;
interface RCPResponse {
stevekrouse avatar
cleverJadePlanarian
@stevekrouse
@jsxImportSource https://esm.sh/hono@latest/jsx
HTTP
/** @jsxImportSource https://esm.sh/hono@latest/jsx **/
const app = new Hono();
// Add a middleware to include the viewport meta tag and additional CSS in all HTML responses
app.use("*", async (c, next) => {
await next();
if (c.res.headers.get("Content-Type")?.includes("text/html")) {
const html = await c.res.text();
const updatedHtml = html.replace(
"</head>",
<meta name="viewport" content="width=device-width, initial-scale=1.0">
iamseeley avatar
valception
@iamseeley
@jsxImportSource npm:hono@3/jsx
HTTP
/** @jsxImportSource npm:hono@3/jsx */
const app = new Hono();
app.get("/", async (c) => {
const depth = parseInt(c.req.query("depth")) || 0;
const nextDepth = depth + 1;
const spinnerGif = "https://media4.giphy.com/media/9UqRcQHzBou6A/giphy.gif?cid=6c09b952dz5ee3qoyzfg0tgxlwhpc46e29h7p432xjb7
return c.html(
<html lang="en">
<head>
<meta charset="UTF-8" />