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=352&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 4692 results for "react"(457ms)

email_capture_system_2ProjectForm.tsx4 matches

@prashamtrivedi•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState } from "https://esm.sh/react@18.2.0";
3import { isValidEmail } from "../../backend/utils.ts";
4
24 const [submitError, setSubmitError] = useState('');
25
26 const handleChange = (e: React.ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => {
27 const { name, value } = e.target;
28 setFormData(prev => ({ ...prev, [name]: value }));
59 };
60
61 const handleSubmit = async (e: React.FormEvent) => {
62 e.preventDefault();
63
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState } from "https://esm.sh/react@18.2.0";
3import { Project, EmailSubscriber } from "../../shared/types.ts";
4
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState } from "https://esm.sh/react@18.2.0";
3import { Project, ProjectStatus, EmailSubscriber } from "../../shared/types.ts";
4import { LoadingSpinner } from "./LoadingSpinner.tsx";

email_capture_system_2Dashboard.tsx2 matches

@prashamtrivedi•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState } from "https://esm.sh/react@18.2.0";
3import { ProjectsList } from "./ProjectsList.tsx";
4import { SubscribersList } from "./SubscribersList.tsx";
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React from "https://esm.sh/react@18.2.0";
3
4export function LoadingSpinner() {

email_capture_system_2Navbar.tsx2 matches

@prashamtrivedi•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React from "https://esm.sh/react@18.2.0";
3
4interface NavbarProps {

email_capture_system_2App.tsx2 matches

@prashamtrivedi•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import React, { useState, useEffect } from "https://esm.sh/react@18.2.0";
3import { Dashboard } from "./Dashboard.tsx";
4import { Navbar } from "./Navbar.tsx";

email_capture_system_2index.html6 matches

@prashamtrivedi•Updated 1 month ago
7 <script src="https://cdn.twind.style" crossorigin></script>
8 <script src="https://esm.town/v/std/catch"></script>
9 <!-- React and dependencies -->
10 <script type="module">
11 import React from "https://esm.sh/react@18.2.0";
12 import ReactDOM from "https://esm.sh/react-dom@18.2.0/client";
13 import { App } from "./components/App.tsx";
14
16 window.twind = window.twind.setup({});
17
18 // Mount React application
19 const root = ReactDOM.createRoot(document.getElementById("app"));
20 root.render(React.createElement(App));
21 </script>
22</head>

FarcasterGalleryFarcasterMiniApp.tsx2 matches

@moe•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@19 */
2import fcsdk from "https://esm.sh/@farcaster/frame-sdk";
3import { useEffect, useState } from "https://esm.sh/react@19";
4import { formatAddress, formatJSON } from "../util/format.ts";
5import { MonoButtonWithStatus, Section } from "./ui.tsx";

FarcasterGalleryuseQuery.ts2 matches

@moe•Updated 1 month ago
1/** @jsxImportSource https://esm.sh/react@19 */
2import { useEffect, useState } from "https://esm.sh/react@19";
3
4export const useQuery = (deps, asyncFn) => {

react-router-starter-remix-13 file matches

@jxnblk•Updated 2 days ago

reactHonoStarter4 file matches

@stfnsr•Updated 4 days ago