1// @ts-nocheck: fiik
2/** @jsxImportSource https://esm.town/v/jxnblk/jsx */
3import { renderToString } from "https://esm.sh/react-dom@19/server";
4
5const styles = {
1import { jsx as reactJSX } from 'https://esm.sh/react@19/jsx-runtime';
2import { Fragment } from "https://esm.sh/react@19";
3import atomic from "https://esm.town/v/jxnblk/tuna/atomic.tsx";
4import type { ElementType, JSX, ReactElement, Key } from "https://esm.sh/react@19";
5
6export { Fragment } from "https://esm.sh/react@19";
7
8// fiik
9export type { ComponentType, ElementType, ReactElement, Key, JSX } from "https://esm.sh/react@19";
10
11interface SXProps {
18 type: ElementType<any, keyof JSX.IntrinsicElements>,
19 props: SXProps|null,
20 key?: Key): ReactElement => {
21 if (props && props.sx) {
22 const { sx, className, ...rest } = props;
27 };
28 // wrap jsx with fragment and result.css style tag
29 return reactJSX(Fragment, {
30 children: [
31 reactJSX("style", {
32 key: key + "sx" + result.css,
33 dangerouslySetInnerHTML: {
35 },
36 }),
37 reactJSX(type, merged, key)
38 ]
39 });
40 }
41
42 return reactJSX(type, props, key);
43}
44
1/** @jsxImportSource https://esm.sh/react@18.2.0?dev */
2import { useState, createContext, useContext } from "react";
3import ReactMarkdown from "react-markdown";
4
5import { Loading } from "./Loading.tsx";
124function TextPart ({ part }) {
125 return (
126 <ReactMarkdown>
127 {part.text}
128 </ReactMarkdown>
129 );
130}
386 {message.parts.map((part, i) => part.type === "text" ? (
387 <div key={i} className="user-message">
388 <ReactMarkdown>
389 {part.text}
390 </ReactMarkdown>
391 </div>
392 ) : (
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2
3import { Hono } from "npm:hono";
1/** @jsxImportSource https://esm.sh/react@18.2.0?dev */
2import React from "npm:react";
3import { Chat } from "./Chat.tsx";
4
146 {
147 "imports": {
148 "npm:react": "https://esm.sh/react@18.2.0?dev",
149 "npm:react-dom": "https://esm.sh/react-dom@18.2.0/client?dev",
150 "npm:react-router": "https://esm.sh/react-router@7.4.0?dev&deps=react@18.2.0,react-dom@18.2.0",
151 "npm:react-use": "https://esm.sh/react-use?dev&deps=react@18.2.0,react-dom@18.2.0",
152 "npm:@ai-sdk/react": "https://esm.sh/@ai-sdk/react?dev&deps=react@18.2.0,react-dom@18.2.0,zod@3.24",
153 "react-markdown": "https://esm.sh/react-markdown?dev&deps=react@18.2.0,react-dom@18.2.0"
154 }
155 }
1# React Hono Starter
2
3This app is a starter template for client-side React and server-side Hono.
4
5- **Remix** this starter template on the top right to get started.
9
10- The **client-side entrypoint** is `/frontend/index.html`, which in turn
11 imports `/frontend/index.tsx`, which in turn imports the React app from
12 `/frontend/components/App.tsx`.
13
14[React Hono Example](https://www.val.town/x/stevekrouse/reactHonoExample) is a
15fuller featured example project, with a SQLite database table, queries,
16client-side CSS and a favicon, and some shared code that runs on both client and
4 <meta charset="UTF-8">
5 <meta name="viewport" content="width=device-width, initial-scale=1.0">
6 <title>React Hono Val Town Starter</title>
7 <script src="https://cdn.tailwindcss.com"></script>
8 <link
1/** @jsxImportSource https://esm.sh/react@18.2.0 */
2import { useState } from "https://esm.sh/react@18.2.0";
3
4interface WebsiteAnalysis {
39 const [activeTab, setActiveTab] = useState<'overview' | 'pages' | 'code'>('overview');
40
41 const handleAnalyze = async (e: React.FormEvent) => {
42 e.preventDefault();
43 if (!url) return;
1/** @jsxImportSource https://esm.sh/react@18.2.0?dev */
2import { createRoot } from "npm:react-dom";
3import React from "npm:react";
4import { App } from "./components/App.tsx";
5