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/$2?q=database&page=3&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 5451 results for "database"(972ms)

Smart_Expense_Trackergoals.ts1 match

@gunjana_04โ€ขUpdated 9 hours ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { addGoal, getGoals, updateGoalProgress, deleteGoal, getTravelDestinations } from "../database/queries.ts";
3
4const goals = new Hono();

Smart_Expense_Trackerexpenses.ts1 match

@gunjana_04โ€ขUpdated 9 hours ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { addExpense, getExpenses, getExpensesByMonth, deleteExpense } from "../database/queries.ts";
3import { getMonthYear } from "../../shared/utils.ts";
4

Smart_Expense_Trackermigrations.ts3 matches

@gunjana_04โ€ขUpdated 9 hours ago
1import { sqlite } from "https://esm.town/v/stevekrouse/sqlite";
2
3// Database schema for the expense tracker
4export async function runMigrations() {
5 console.log("Running database migrations...");
6
7 // Users table
158 }
159
160 console.log("Database migrations completed!");
161}

Smart_Expense_TrackerREADME.md3 matches

@gunjana_04โ€ขUpdated 9 hours ago
33```
34โ”œโ”€โ”€ backend/
35โ”‚ โ”œโ”€โ”€ database/
36โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Database schema
37โ”‚ โ”‚ โ””โ”€โ”€ queries.ts # Database operations
38โ”‚ โ”œโ”€โ”€ routes/
39โ”‚ โ”‚ โ”œโ”€โ”€ expenses.ts # Expense CRUD operations

untitled-9454README.md2 matches

@Varun07โ€ขUpdated 9 hours ago
8- ๐Ÿ“ User registration
9- ๐Ÿช Session management with cookies
10- ๐Ÿ’พ SQLite database for user storage
11- ๐ŸŽจ Beautiful UI with TailwindCSS
12- ๐Ÿ“ฑ Responsive design
41- `GET /api/auth` - Check authentication status
42
43## Database Schema
44
45The app uses SQLite with a simple users table:

untitled-9454index.ts5 matches

@Varun07โ€ขUpdated 9 hours ago
11});
12
13// Database setup
14const TABLE_NAME = 'login_users_1';
15
16// Initialize database
17async function initDatabase() {
18 await sqlite.execute(`CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (
19 id INTEGER PRIMARY KEY AUTOINCREMENT,
34}
35
36// Initialize database on startup
37await initDatabase();
38
39// Serve static files

cerebras_codermain.tsx2 matches

@Catspindevโ€ขUpdated 9 hours ago
1import { serveFile } from "https://esm.town/v/std/utils/index.ts";
2import { generateCode } from "./backend/generate-code.ts";
3import { createTables } from "./database/migrations.ts";
4import { createProject, getCode, getNextVersionNumber, insertVersion } from "./database/queries.ts";
5
6await createTables();

reactHonoStarterREADME.md1 match

@stdโ€ขUpdated 9 hours ago
21## Further resources
22
23- [React Hono Example](https://www.val.town/x/stevekrouse/reactHonoExample) is a bigger example project, with a SQLite database table, queries, client-side CSS, a favicon, and shared code that runs on both client and server.

Websiteindex.ts2 matches

@w_acheโ€ขUpdated 9 hours ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { readFile, serveFile } from "https://esm.town/v/std/utils@85-main/index.ts";
3import { runMigrations } from "./database/migrations.ts";
4import api from "./routes/api.ts";
5
11});
12
13// Initialize database
14await runMigrations();
15

Websiteapi.ts1 match

@w_acheโ€ขUpdated 9 hours ago
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { getAllProducts, getProductById, createTransaction } from "../database/queries.ts";
3import type { PurchaseRequest, PurchaseResponse } from "../../shared/types.ts";
4

bookmarksDatabase

@s3thiโ€ขUpdated 3 months ago

sqLiteDatabase1 file match

@ideofunkโ€ขUpdated 6 months ago