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=822&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 8591 results for "react"(1239ms)

staticChessmain.tsx2 matches

@compuives•Updated 11 months ago
1/** @jsxImportSource https://esm.sh/react */
2import { modifyFetchHandler as codeOnValTown } from "https://esm.town/v/andreterron/codeOnValTown?v=45";
3import { modifyResponse } from "https://esm.town/v/andreterron/codeOnVT_modifyResponse?v=9";
5import { Chess, Move, Square } from "npm:chess.js";
6import minify from "npm:css-simple-minifier";
7import { renderToString } from "npm:react-dom/server";
8
9class StaticChess {

staticChessmain.tsx2 matches

@wesleychiyoka•Updated 11 months ago
1/** @jsxImportSource https://esm.sh/react */
2import { Chess, Move, Square } from "npm:chess.js";
3import minify from "npm:css-simple-minifier";
4import { renderToString } from "npm:react-dom/server";
5
6class StaticChess {

staticChessmain.tsx2 matches

@rickygrassmuck•Updated 11 months ago
1/** @jsxImportSource https://esm.sh/react */
2import { Chess, Move, Square } from "npm:chess.js";
3import minify from "npm:css-simple-minifier";
4import { renderToString } from "npm:react-dom/server";
5
6class StaticChess {

linkInBioTemplatemain.tsx2 matches

@stevekrouse•Updated 11 months ago
1/** @jsxImportSource https://esm.sh/react */
2import { renderToString } from "npm:react-dom/server";
3
4export default async function(req: Request) {

cron_client_react_forkmain.tsx5 matches

@stevekrouse•Updated 11 months ago
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import cronstrue from "https://esm.sh/cronstrue";
3import React, { useState } from "https://esm.sh/react@18.2.0";
4import { chat } from "https://esm.town/v/stevekrouse/openai?v=19";
5import react_http from "https://esm.town/v/stevekrouse/react_http?v=6";
6
7export default function(req: Request) {
8 const url = new URL(req.url);
9 if (req.method === "GET" && url.pathname === "/") {
10 return react_http({
11 component: App,
12 sourceURL: import.meta.url,
26 const [loading, setLoading] = useState(false);
27 const [cron, setCron] = useState("0 16 * * 1-5");
28 const onSubmit: React.FormEventHandler<HTMLFormElement> = async function(e) {
29 e.preventDefault();
30 setLoading(true);

react_httpmain.tsx2 matches

@stevekrouse•Updated 11 months ago
6 <script type="module">
7 import { ${component.name} } from "${sourceURL}";
8 import { createRoot } from "https://esm.sh/react-dom@18.2.0/client";
9 import { jsx } from "https://esm.sh/react@18.2.0/jsx-runtime";
10 createRoot(document.body).render(jsx(${component.name}, {}));
11 </script>

cron_client_react_forkREADME.md2 matches

@stevekrouse•Updated 11 months ago
12## TODO
13
14- [ ] simplify by removing HTMX (try doing the form as a GET request, manual JS script, or client side react)
15- [ ] make the timezone picker better (fewer options, searchable)
16- [ ] add a copy button?
17
18Migrated from folder: Archive/cron_client_react_fork

orangeHellomain.tsx2 matches

@kirineko•Updated 12 months ago
1/** @jsxImportSource npm:react **/
2import { renderToString } from "npm:react-dom@18/server";
3
4export default (req: Request) => {

blog_mdxmain.tsx4 matches

@pomdtr•Updated 12 months ago
1/** @jsxImportSource https://esm.sh/preact **/
2
3import { blob } from "https://esm.town/v/std/blob?v=12";
4import { compile } from "npm:@mdx-js/mdx";
5import { Hono } from "npm:hono";
6import { render } from "npm:preact-render-to-string";
7import remarkFrontmatter from "npm:remark-frontmatter";
8import remarkMdxFrontmatter from "npm:remark-mdx-frontmatter";
51 const vfile = await compile(await resp.text(), {
52 jsx: true,
53 jsxImportSource: "https://esm.sh/preact",
54 remarkPlugins: [remarkFrontmatter, remarkMdxFrontmatter],
55 });
63
64 const vfile = await compile(await resp.text(), {
65 jsxImportSource: "https://esm.sh/preact",
66 remarkPlugins: [remarkFrontmatter, remarkMdxFrontmatter],
67 });

isthegtrainfuckedmain.tsx2 matches

@stevekrouse•Updated 12 months ago
1/** @jsxImportSource https://esm.sh/preact */
2import { activeGTrainAlerts } from "https://esm.town/v/pbt/gtrainalerts?v=36";
3import { render } from "npm:preact-render-to-string";
4import Uwuifier from "npm:uwuifier";
5

vt-discord4 file matches

@boucher•Updated 2 days ago
Starter template with client-side React & Hono server

diceRollerUI1 file match

@dcm31•Updated 2 days ago
A web-based dice roller using React on Val Town
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