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/$1?q=react&page=1187&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 16305 results for "react"(1431ms)

windsurf_projectContextmain.tsx13 matches

@Emailscompelling•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
3import React, { useEffect, useState } from "https://esm.sh/react@18.2.0";
4
5// API Documentation
43/**
44 * Main App component
45 * @returns {React.ReactElement}
46 */
47function App() {
118 * CurrentPhase component
119 * @param {{phase: string, onUpdate: Function}} props
120 * @returns {React.ReactElement}
121 */
122function CurrentPhase({ phase, onUpdate }) {
126 /**
127 * Handles form submission
128 * @param {React.FormEvent} e - The form event
129 */
130 const handleSubmit = (e) => {
158 * ActiveBlocks component
159 * @param {{blocks: string[], onUpdate: Function}} props
160 * @returns {React.ReactElement}
161 */
162function ActiveBlocks({ blocks = [], onUpdate }) {
166 /**
167 * Handles form submission
168 * @param {React.FormEvent} e - The form event
169 */
170 const handleSubmit = (e) => {
216 * TaskList component
217 * @param {{tasks: Task[], onUpdate: Function}} props
218 * @returns {React.ReactElement}
219 */
220function TaskList({ tasks = [], onUpdate }) {
226 /**
227 * Handles form submission
228 * @param {React.FormEvent} e - The form event
229 */
230 const handleSubmit = (e) => {
344 * StepList component
345 * @param {{steps: Step[], onUpdate: Function}} props
346 * @returns {React.ReactElement}
347 */
348function StepList({ steps = [], onUpdate }) {
354 /**
355 * Handles form submission
356 * @param {React.FormEvent} e - The form event
357 */
358 const handleSubmit = (e) => {
458 * ChangeList component
459 * @param {{changes: Change[]}} props
460 * @returns {React.ReactElement}
461 */
462function ChangeList({ changes = [] }) {

cerebras_coderindex10 matches

@usuf•Updated 2 months 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>

eink-frameweather.tsx3 matches

@michaelwschultz•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react */
2import React from "https://esm.sh/react";
3import { renderToString } from "https://esm.sh/react-dom/server";
4import GetWeather, { type WEATHER_FORECAST } from "../api/weather.ts";
5import { BodyWrapper, Content, Footer, Header, Headline } from "../components.tsx";

eink-framenews.tsx3 matches

@michaelwschultz•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react */
2import React from "https://esm.sh/react";
3import { renderToString } from "https://esm.sh/react-dom/server/";
4import GetNews from "../api/news.ts";
5import { BodyWrapper, Content, Footer, Header, Headline } from "../components.tsx";

eink-frameapod.tsx3 matches

@michaelwschultz•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react */
2import React from "https://esm.sh/react";
3import { renderToString } from "https://esm.sh/react-dom/server/";
4import GetAPOD, { type APOD } from "../api/apod.ts";
5import { BodyWrapper, Header } from "../components.tsx";

eink-framefontsTest.tsx3 matches

@michaelwschultz•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react */
2import React from "https://esm.sh/react";
3import { renderToString } from "https://esm.sh/react-dom/server";
4import { BodyWrapper, Content, Footer, Header, Headline } from "../components.tsx";
5

valentinemain.tsx3 matches

@rapilot330•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
3import React, { useState } from "https://esm.sh/react@18.2.0";
4
5const NO_PHRASES = [

jobPostChatAppmain.tsx3 matches

@pastoreekahk96•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState, useEffect } from "https://esm.sh/react@18.2.0";
3import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
4
5// Configuration for Google Sheets API

kenbilconcepts_bio_pagemain.tsx3 matches

@kenbil1119•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState, useRef, useCallback, useEffect } from "https://esm.sh/react@18.2.0";
3import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
4
5function WhatsAppIcon() {

ATProtoOAuthStartermain.tsx5 matches

@wilhelm•Updated 2 months ago
1/** @jsxImportSource https://esm.sh/react@19.0.0 */
2import { XRPC } from "npm:@atcute/client@2.0.8";
3import {
10} from "npm:@atcute/oauth-browser-client@1.0.15";
11import { Hono } from "npm:hono@4.7.2";
12import React, { useActionState, useEffect, useRef, useState } from "npm:react";
13import { createRoot } from "npm:react-dom/client";
14
15const [, , username, valname] = new URL(import.meta.url).pathname.split("/").map(s => s.toLowerCase());
150 "npm:@atcute/oauth-browser-client@1.0.15": "https://esm.sh/@atcute/oauth-browser-client@1.0.15",
151 "npm:hono@4.7.2": "https://esm.sh/hono@4.7.2",
152 "npm:react": "https://esm.sh/react@19.0.0",
153 "npm:react-dom/client": "https://esm.sh/react-dom@19.0.0/client"
154 }
155 }

reactHonoStarter4 file matches

@halfstack•Updated 11 hours ago

MiniAppStarter10 file matches

@moe•Updated 13 hours ago
Hono + React + Tailwind + Farcaster Mini App Starter Project
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