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=836&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"(1770ms)

myReactAppmain.tsx8 matches

@liamdanielduffy•Updated 1 year ago
1import { initializeReactApp as initializeReactApp2 } from "https://esm.town/v/liamdanielduffy/initializeReactApp";
2import { myReactComponent as myReactComponent2 } from "https://esm.town/v/liamdanielduffy/myReactComponent";
3import { addReactFromCDN } from "https://esm.town/v/liamdanielduffy/addReactFromCDN";
4
5export function myReactApp() {
6 const loadReact = addReactFromCDN();
7 const myReactComponent = myReactComponent2();
8 const initializeReactApp = initializeReactApp2();
9 return [loadReact, myReactComponent, initializeReactApp].join(" ");
10}

myApimain.tsx1 match

@sbeben•Updated 1 year ago
12 root;
13 ">Hello World</div><script src=";
14 path_to_your_react_app.js;
15 "></script></body></html>`;
16}

reactmain.tsx1 match

@andreterron2•Updated 1 year ago
1export const react = await import("npm:react");

runAgentmain.tsx1 match

@jacoblee93•Updated 1 year ago
80 ];
81 const agent = await initializeAgentExecutorWithOptions(tools, model, {
82 agentType: "chat-conversational-react-description",
83 });
84 const result = await agent.call({

REACT_DOM_MINIFIED_FINALmain.tsx10 matches

@liamdanielduffy•Updated 1 year ago
1import { REACT_DOM_MINIFIED_PT4 } from "https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED_PT4";
2import { REACT_DOM_MINIFIED_PT3 } from "https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED_PT3";
3import { REACT_DOM_MINIFIED_PT2 } from "https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED_PT2";
4import { REACT_DOM_MINIFIED_PT1 } from "https://esm.town/v/liamdanielduffy/REACT_DOM_MINIFIED_PT1";
5
6//this is necessary because I can't store the entire React DOM minified code inside a Val as a string, too long :()
7export const REACT_DOM_MINIFIED_FINAL = [
8 REACT_DOM_MINIFIED_PT1,
9 REACT_DOM_MINIFIED_PT2,
10 REACT_DOM_MINIFIED_PT3,
11 REACT_DOM_MINIFIED_PT4,
12].join("");

preactWebAppmain.tsx17 matches

@easrng•Updated 1 year ago
1export const preactWebApp = (function () {
2 type propType =
3 & {
11 ...values: any[]
12 ) =>
13 | import("npm:preact@10.17.0").VNode<
14 import("npm:preact@10.17.0").Attributes
15 >
16 | import("npm:preact@10.17.0").VNode<
17 import("npm:preact@10.17.0").Attributes
18 >[];
19 }
20 & typeof import("npm:preact@10.17.0")
21 & typeof import("npm:preact@10.17.0/hooks");
22 const preactWebApp =
23 (App: (_: propType) => import("npm:preact@10.17.0").VNode) =>
24 async (req: express.Request, res: express.Response) => {
25 const preact = await import("npm:preact@10.17.0");
26 const hooks = await import("npm:preact@10.17.0/hooks");
27 const _renderToString = await import("npm:preact-render-to-string@6.2.1");
28 const { renderToString } = _renderToString;
29 const { default: htm } = await import("npm:htm@3.1.1");
30 const html = htm.bind(preact.h);
31 try {
32 let status = 200;
43 headers = h;
44 },
45 ...preact,
46 ...hooks,
47 };
57 console.error(etext);
58 res.status(500);
59 res.send(renderToString(preact.h(
60 "html",
61 null,
69 }
70 };
71 preactWebApp.props = {} as propType;
72 return preactWebApp;
73}).call(this);

addReactFromCDNmain.tsx6 matches

@liamdanielduffy•Updated 1 year ago
1import { scriptTag } from "https://esm.town/v/liamdanielduffy/scriptTag";
2
3export function addReactFromCDN(): string {
4 const reactDom = scriptTag({
5 src: "https://unpkg.com/react-dom@18.2.0/umd/react-dom.production.min.js",
6 });
7 const react = scriptTag({
8 src: "https://unpkg.com/react@18/umd/react.production.min.js",
9 });
10 return [react, reactDom].join(" ");
11}

myReactComponentmain.tsx4 matches

@liamdanielduffy•Updated 1 year ago
1// assumes React is in scope, and returns a valid HTML script string for rendering a React Component
2export function myReactComponent() {
3 return `
4const Example = () => {
5 return React.createElement("div", null, "Hello, React!");
6};
7
8ReactDOM.render(React.createElement(Example), document.getElementById("root"));
9 `;
10}

resumemain.tsx4 matches

@ajax•Updated 1 year ago
57 }],
58 "skills": [{
59 "keywords": ["HTML / JSX", "SCSS / CSS / BEM / Styled Components", "Javascript / Typescript", "React / Next", "Redux / Apollo"],
60 "level": "Senior",
61 "name": "Frontend"
82 "position": "Senior Javascript Developer",
83 "startDate": "2020-05-05",
84 "highlights": ["Tokenized is a Bitcoin wallet for issuing, managing and trading digital tokens. I built out the front end which was packaged as an electron app. It was a difficult frontend to build because we store the users keys locally and used them to sign transactions and contracts.", "React", "Redux", "SCSS", "Product"],
85 "startDateYear": "2020",
86 "startDateMonth": "May ",
94 "startDate": "2018-03-01",
95 "endDate": "2020-01-01",
96 "highlights": ["Blockbid is an Australian crypto currency exchange. I started off on the frontend but eventually became lead tech and worked on every moving piece of the exchange. I really enjoyed working with liquidity providers and connecting their platforms to help us achieve liquid markets.", "React, Apollo, Styled Components", "Node.js / Rails", "Docker / Heroku / GCP", "Used Figma for design and UX work", "Optimizing markets with tens of millions of rows using SQL."],
97 "startDateYear": "2018",
98 "startDateMonth": "March ",
101 "boolHighlights": true
102 }, {
103 "highlights": ["Built a very large and complex React / Redux application. It works on all platforms and has IOS/Android builds due to it being a PWA. (wrapped it in React Native though only implementing a WebView)", "Worked with Postgres, Redis and Dynamodb for storage.", "Hosted on a mixture of Heroku Apps and EC2 servers.", "Caching by Fastly and Cloudflare", "Hybrid app supported on all platforms"],
104 "website": "https://listium.com",
105 "pinned": true,

preactTestmain.tsx2 matches

@tmcw•Updated 1 year ago
1export const preactTest = (async () => {
2 const { useState, h, htm, renderToString } = await import(
3 "https://npm.reversehttp.com/preact,htm,preact/hooks,preact-render-to-string"
4 );
5 const html = htm.bind(h);

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