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/image-url.jpg%20%22Image%20title%22?q=database&page=340&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=database

Returns an array of strings in format "username" or "username/projectName"

Found 4145 results for "database"(659ms)

jamzmain.tsx1 match

@allโ€ขUpdated 1 month ago
637
638// --- Server-side logic ---
639// --- REVERTED to match the database interactions of your ORIGINAL code ---
640export default async function server(req: Request): Promise<Response> {
641 const { sqlite } = await import("https://esm.town/v/stevekrouse/sqlite");

zanyBeigeFoxmain.tsx1 match

@Nxnxnxnndndโ€ขUpdated 1 month ago
16 apiKey: "AIzaSyBRdHIXJcFUMV3h7k2GFg9wY0S_hUttaZU",
17 authDomain: "tommy-ai-image-generator-d2466.firebaseapp.com",
18 databaseURL: "https://tommy-ai-image-generator-d2466-default-rtdb.firebaseio.com",
19 projectId: "tommy-ai-image-generator-d2466",
20 storageBucket: "tommy-ai-image-generator-d2466.firebasestorage.app",

FarcasterGalleryREADME.md1 match

@moeโ€ขUpdated 1 month ago
9- The **client-side entrypoint** is `/frontend/index.html`, which in turn imports `/frontend/index.tsx`, which in turn imports the React app from `/frontend/App.tsx`.
10
11[React Hono Example](https://www.val.town/x/stevekrouse/reactHonoExample) is a fuller featured example project, with a SQLite database table, queries, client-side CSS and a favicon, and some shared code that runs on both client and server.

react-hono-with-react-routerREADME.md1 match

@stevekrouseโ€ขUpdated 1 month ago
9- The **client-side entrypoint** is `/frontend/index.html`, which in turn imports `/frontend/index.tsx`, which in turn imports the React app from `/frontend/components/App.tsx`.
10
11[React Hono Example](https://www.val.town/x/stevekrouse/reactHonoExample) is a fuller featured example project, with a SQLite database table, queries, client-side CSS and a favicon, and some shared code that runs on both client and server.

timelineindex.ts3 matches

@tmcwโ€ขUpdated 1 month ago
16const CARDS_TABLE = "timeline_cards";
17
18// Sample cards for each set (in a real app, these would be in the database)
19const SAMPLE_CARDS: Record<string, Card[]> = {
20 "random-history": random_history,
208};
209
210// Initialize database
211const initDb = async () => {
212 // Create games table
238};
239
240// Initialize database on startup
241initDb();
242

timelineindex.ts3 matches

@shouserโ€ขUpdated 1 month ago
14const CARDS_TABLE = "timeline_cards";
15
16// Sample cards for each set (in a real app, these would be in the database)
17const SAMPLE_CARDS: Record<string, Card[]> = {
18 "random-history": [
556};
557
558// Initialize database
559const initDb = async () => {
560 // Create games table
586};
587
588// Initialize database on startup
589initDb();
590

OpenTownieTODOs.md1 match

@jxnblkโ€ขUpdated 1 month ago
7- [ ] Rebuild as React Router?
8- [ ] opentownie as a pr bot
9- [ ] give it the ability to see its own client-side and server-side logs by building a middleware that shoves them into a SQL light database date and then give it a tool to access them or use our trpc API in that tool
10- [ ] do a browser use or screenshot thing to give it access to its own visual output
11- [ ] Have it default to creating a new branch off main and then embedding and iframe to the resulting http val and give you a link to a pr opening url

OpenTowniethink.ts1 match

@jxnblkโ€ขUpdated 1 month ago
7export const thinkTool = tool({
8 description:
9 "Use the tool to think about something. It will not obtain new information or change the database, but just append the thought to the log. Use it when complex reasoning or some cache memory is needed.",
10 parameters: z.object({
11 thought: z.string().describe("A thought to think about."),

OpenTowniesystem_prompt.txt2 matches

@jxnblkโ€ขUpdated 1 month ago
166```
167โ”œโ”€โ”€ backend/
168โ”‚ โ”œโ”€โ”€ database/
169โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Schema definitions
170โ”‚ โ”‚ โ”œโ”€โ”€ queries.ts # DB query functions
228- Handle API calls properly with proper error catching
229
230### Database Patterns
231- Run migrations on startup or comment out for performance
232- Change table names when modifying schemas rather than altering

reactHonoExampleREADME.md2 matches

@shouserโ€ขUpdated 1 month ago
4
5* `index.ts` - this is the **entrypoint** for this whole project
6* `database/` - this contains the code for interfacing with the app's SQLite database table
7
8## Hono
26## CRUD API Routes
27
28This app has two CRUD API routes: for reading and inserting into the messages table. They both speak JSON, which is standard. They import their functions from `/backend/database/queries.ts`. These routes are called from the React app to refresh and update data.
29
30## Errors

bookmarksDatabase

@s3thiโ€ขUpdated 2 months ago

sqLiteDatabase1 file match

@ideofunkโ€ขUpdated 5 months ago