Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/?q=react&page=566&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=react

Returns an array of strings in format "username" or "username/projectName"

Found 9479 results for "react"(1437ms)

dotcom

dotcomanalytics.tsx1 match

@jxnblk•Updated 1 month ago
1// visits
2import { DataRequest } from "https://esm.town/v/jxnblk/reactstream/index.tsx";
3
4const API = "https://jxnblk-api.web.val.run/visits";
dotcom

dotcomrss.tsx1 match

@jxnblk•Updated 1 month ago
2
3// import data from "https://blog.jxnblk.com/api/all.json" with { type: "json" };
4import type { Middleware } from "https://esm.town/v/jxnblk/reactstream/index.tsx";
5
6function generateRSSFeed(posts) {
dotcom

dotcomvantom.http.tsx2 matches

@jxnblk•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.3.1 */
2import { renderToStaticMarkup } from "https://esm.sh/react-dom@18.3.1/server";
3
4export const Vantom = ({
dotcom

dotcomreact-svg-to-png.tsx3 matches

@jxnblk•Updated 1 month ago
1/** @jsxImportSource npm:react@18.3.1 */
2import { render as renderPNG } from "https://deno.land/x/resvg_wasm@0.2.0/mod.ts";
3import { renderToStaticMarkup } from "npm:react-dom@18.3.1/server";
4
5type SVGComponentProps = {
10const cache = new Map();
11
12export function render(Component: React.ComponentType<SVGComponentProps>, headers: any = {}) {
13 return async function(req: Request): Promise<Response> {
14 const url = new URL(req.url);

project_updates_webhookindex.tsx2 matches

@shouser•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
3import { type Message } from "../shared/utils.ts";
4import { App } from "./components/App.tsx";
dotcom

dotcomog-image.http.tsx2 matches

@jxnblk•Updated 1 month ago
1/** @jsxImportSource npm:react@18.3.1 */
2import wrap from "npm:word-wrap";
3// make this a library
4import { render } from "./react-svg-to-png.tsx";
5import { Avatar } from "./avatar.tsx";
6import { Diagz, Tiled } from "./greebles.tsx";
dotcom

dotcomgreebles.tsx3 matches

@jxnblk•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.3.1 */
2import { type ReactNode, SVGProps } from "https://esm.sh/react@18.3.1";
3
4type IconProps = SVGProps<SVGSVGElement> & {
42
43type TiledProps = IconProps & {
44 children: ReactNode;
45 offset?: number | string;
46};
dotcom

dotcomavatar.tsx3 matches

@jxnblk•Updated 1 month ago
1// jxnblk avatar.
2/** @jsxImportSource https://esm.sh/react@18.3.1 */
3import { renderToStaticMarkup } from "https://esm.sh/react-dom@18.3.1/server";
4import { SVGProps } from "https://esm.sh/react@18.3.1";
5
6type AvatarProps = SVGProps<SVGSVGElement> & {

chuck_norris_respondermain.tsx1 match

@ajax•Updated 1 month ago
15 model: openai("gpt-4o-mini"),
16 system: "You are Chuck Norris, known for humorous and exaggerated responses.",
17 prompt: `Create a funny and morbid response as if Chuck Norris were reacting to the situation: ${situation}, involving the user: ${user_name}.`,
18 });
19 return Response.json({ response: chuckResponse });

cerebras_coderindex10 matches

@sukanya20•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import { createRoot } from "https://esm.sh/react-dom@18.2.0/client?deps=react@18.2.0";
3import { Prism as SyntaxHighlighter } from "https://esm.sh/react-syntax-highlighter?deps=react@18.2.0,react-dom@18.2.0";
4import React, { useEffect, useState } from "https://esm.sh/react@18.2.0";
5import STARTER_PROMPTS from "./starter-prompts.js";
6
30}: {
31 prompt: string;
32 setPrompt: React.Dispatch<React.SetStateAction<string>>;
33 handleSubmit: (e: React.FormEvent) => void;
34 handleStarterPromptClick: (promptItem: PromptItem) => void;
35}) {
116
117function App() {
118 const previewRef = React.useRef<HTMLDivElement>(null);
119 const [prompt, setPrompt] = useState("");
120 const [projectId, setProjectId] = useState<number | null>(null);
174 }
175
176 async function handleSubmit(e: React.FormEvent | string) {
177 if (typeof e !== "string") {
178 e.preventDefault();
673 </div>
674 <div className="bg-white w-full h-full flex flex-col grow rounded-xl border-2 border-white overflow-hidden">
675 <React.Fragment key={iframeKey}>
676 <iframe
677 srcDoc={code}
679 className="w-full grow"
680 />
681 </React.Fragment>
682 </div>
683 </div>

reactHonoStarter4 file matches

@texoport•Updated 16 hours ago

new_website

@wolf•Updated 2 days ago
Starter template with client-side React & Hono server
effector
Write business logic with ease Meet the new standard for modern TypeScript development. Type-safe, reactive, framework-agnostic library to manage your business logic.
officialrajdeepsingh
Follow me if you learn more about JavaScript | TypeScript | React.js | Next.js | Linux | NixOS | Frontend Developer | https://linktr.ee/officialrajdeepsingh