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?q=database&page=171&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 6935 results for "database"(4138ms)

MYHEALTHSOURCEmigrations.ts3 matches

@SIR_FESTUSโ€ขUpdated 1 week ago
1import { sqlite } from "https://esm.town/v/stevekrouse/sqlite";
2
3// Database schema for the health platform
4export async function runMigrations() {
5 console.log("Running database migrations...");
6
7 // Users table
182 `);
183
184 console.log("Database migrations completed successfully!");
185}
186

MYHEALTHSOURCEappointments.ts1 match

@SIR_FESTUSโ€ขUpdated 1 week ago
6 getAppointmentById,
7 updateAppointmentStatus
8} from "../database/queries.ts";
9
10const appointments = new Hono();

MYHEALTHSOURCEhealth.ts1 match

@SIR_FESTUSโ€ขUpdated 1 week ago
8 getBMIHistoryByUser,
9 getDashboardData
10} from "../database/queries.ts";
11
12const health = new Hono();

reactHonoStarterREADME.md1 match

@tsuchi_yaโ€ขUpdated 1 week 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.

untitled-7598index.ts2 matches

@c15rโ€ขUpdated 1 week ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { runMigrations } from "./database/migrations.ts";
3import boardsRouter from "./routes/boards.ts";
4import staticRouter from "./routes/static.ts";
11});
12
13// Initialize database
14await runMigrations();
15

untitled-7598static.ts1 match

@c15rโ€ขUpdated 1 week ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { readFile, serveFile } from "https://esm.town/v/std/utils/index.ts";
3import * as db from "../database/queries.ts";
4
5const app = new Hono();

untitled-7598boards.ts1 match

@c15rโ€ขUpdated 1 week ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import * as db from "../database/queries.ts";
3import type {
4 CreateColumnRequest,

untitled-7598README.md4 matches

@c15rโ€ขUpdated 1 week ago
15```
16โ”œโ”€โ”€ backend/
17โ”‚ โ”œโ”€โ”€ database/
18โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Database schema setup
19โ”‚ โ”‚ โ””โ”€โ”€ queries.ts # Database query functions
20โ”‚ โ”œโ”€โ”€ routes/
21โ”‚ โ”‚ โ”œโ”€โ”€ boards.ts # Board management endpoints
51## Getting Started
52
531. The backend will automatically create the necessary database tables on startup
542. Navigate to the root URL to access the kanban board interface
553. Create columns and start adding items to organize your work

con-juanREADME.md8 matches

@Downchuckโ€ขUpdated 1 week ago
19 - **Temporary Sessions (Default)**: No data saved anywhere - maximum privacy
20 - **Local Storage**: Sessions saved only in your browser - private and secure
21 - **Server Storage**: Full AI analysis with persistent sessions saved to database
22- **Data Management**: Clear saved data with one click
23 - Delete individual sessions
55โ”‚ โ”‚ โ”œโ”€โ”€ power-abuse-analyzer.ts # Text analysis API
56โ”‚ โ”‚ โ””โ”€โ”€ static-file-server.ts # Static file server
57โ”‚ โ”œโ”€โ”€ database/ # Database operations
58โ”‚ โ”‚ โ””โ”€โ”€ index.ts # SQLite database operations
59โ”‚ โ”œโ”€โ”€ utils/ # Utility functions
60โ”‚ โ”‚ โ”œโ”€โ”€ error-handler.ts # Error handling and response formatting
65โ”‚ โ”œโ”€โ”€ analyzer.test.ts # Tests for text analysis
66โ”‚ โ”œโ”€โ”€ chat-api.test.ts # Tests for chat API
67โ”‚ โ”œโ”€โ”€ database.test.ts # Tests for database operations
68โ”‚ โ””โ”€โ”€ README.md # Test documentation
69โ”œโ”€โ”€ frontend/ # Frontend files
73```
74
75## Database Schema
76
77The application uses SQLite with the following tables:
82- **Examples**: Stores examples of patterns, including user-provided examples
83
84The database uses recursive common table expressions (CTEs) to handle threaded conversations about specific patterns.
85
86## Usage
99 - **๐Ÿ”’ Temporary (Default)**: No data saved anywhere - maximum privacy
100 - **๐Ÿ’พ Local Storage**: Sessions saved only in your browser - private and secure
101 - **โ˜๏ธ Server Storage**: Full AI-powered analysis with sessions saved to the database
1024. Create a new analysis session
1035. Enter text to analyze or ask a question about power abuse patterns
117- **๐Ÿ’พ Local Storage**: Sessions are saved only in your browser's local storage. This provides privacy as data never leaves your device, but with limited analysis capabilities (no AI processing). Sessions are only available on the device where they were created.
118
119- **โ˜๏ธ Server Storage**: Sessions are saved to the SQLite database on the server. This provides full AI-powered analysis using Cerebras Qwen-3 32B model, persistent sessions that can be accessed from any device, and complete pattern recognition capabilities.
120
121## Prompts Used

con-juanchat-api.ts4 matches

@Downchuckโ€ขUpdated 1 week ago
1import * as db from "../database/index.ts";
2import { analyzeText } from "../analyzer/index.ts";
3import { handlePatternFollowUp } from "../analyzer/index.ts";
8const log = logger.createLogger('API:ChatAPI');
9
10// Initialize database
11await db.initDatabase();
12
13// Types for our API
58 const analysisResult = await analyzeText(message);
59
60 // Store identified patterns in the database
61 const messageId = await db.addMessage(session_id, message, "user", parent_id);
62 const storedPatterns: db.Pattern[] = [];

bookmarksDatabase

@s3thiโ€ขUpdated 3 months ago

sqLiteDatabase1 file match

@ideofunkโ€ขUpdated 6 months ago