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=115&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 4634 results for "database"(1258ms)

productpanelgetApps.http.ts1 match

@tijsโ€ขUpdated 2 weeks ago
25
26 try {
27 // Get all apps from the database
28 const apps = await getAllApps();
29

productpaneldeleteApp.http.ts1 match

@tijsโ€ขUpdated 2 weeks ago
44 }
45
46 // Delete the app from the database
47 const deleted = await deleteApp(appId);
48

productpanelcreateApp.http.ts1 match

@tijsโ€ขUpdated 2 weeks ago
39 const apiKey = generateApiKey();
40
41 // Create the app in the database
42 const app = await createApp({
43 name: validation.data.name!,

productpanelsubmitFeedback.http.ts1 match

@tijsโ€ขUpdated 2 weeks ago
50
51 /**
52 * Create the feedback in the database with the following fields:
53 *
54 * Basic fields:

productpanelmigrations.ts2 matches

@tijsโ€ขUpdated 2 weeks ago
1/**
2 * Database migrations for productpanel
3 * Handles schema updates and migrations
4 */
63
64/**
65 * Check if a table exists in the database
66 */
67async function checkTableExists(tableName: string): Promise<boolean> {

productpanelinit.ts8 matches

@tijsโ€ขUpdated 2 weeks ago
1/**
2 * Database initialization for productpanel
3 * Creates required tables if they don't exist
4 */
8
9/**
10 * Initialize the database by creating required tables
11 * Only needs to be run once when the app starts
12 */
13export async function initializeDatabase() {
14 try {
15 // Create apps table
23 return { success: true };
24 } catch (error) {
25 console.error("Error initializing database:", error);
26 return {
27 success: false,
32
33/**
34 * Reset database (for development use only)
35 * Drops existing tables and recreates them
36 */
37export async function resetDatabase() {
38 try {
39 // Drop tables if they exist (reverse order due to foreign key)
42
43 // Recreate tables
44 return await initializeDatabase();
45 } catch (error) {
46 console.error("Error resetting database:", error);
47 return {
48 success: false,

productpanelschema.ts1 match

@tijsโ€ขUpdated 2 weeks ago
1/**
2 * Database schema for productpanel
3 * Contains table definitions for apps and feedback
4 */

productpanelapiKey.ts2 matches

@tijsโ€ขUpdated 2 weeks ago
27
28/**
29 * Validate an API key against the database
30 * @param apiKey The API key to validate
31 * @returns The app object if valid, null if invalid
36 }
37
38 // Check if the API key exists in the database
39 const app = await getAppByApiKey(apiKey);
40 return app;

productpanelvalidation.ts1 match

@tijsโ€ขUpdated 2 weeks ago
176 }
177
178 // Return cleaned data mapped to our database field names
179 return {
180 valid: true,

productpanelDESIGN_BRIEF.md5 matches

@tijsโ€ขUpdated 2 weeks ago
3## 1. Project Overview
4
5**AppFeedback.val** is a personal service for collecting, storing, and viewing user feedback from your apps. Built exclusively on Val Town, the service will leverage TypeScript with Deno runtime and Val Town's built-in SQLite database for data storage. This project is designed for personal use, allowing you to collect feedback from one or more of your applications and view it in a consolidated dashboard.
6
7## 2. Technical Requirements
10- **Runtime:** Deno (Val Town's native runtime)
11- **Programming Language:** TypeScript
12- **Database:** Val Town's built-in SQLite database (limit: 10MB free, 1GB paid)
13- **Authentication:** Simple API key authentication for your apps to send feedback
14- **Frontend:** HTML/CSS/JS served directly from Val Town HTTP vals
61โ”œโ”€โ”€ index.ts # Main entry point for the project
62โ”œโ”€โ”€ db/
63โ”‚ โ”œโ”€โ”€ schema.ts # Database schema definitions
64โ”‚ โ”œโ”€โ”€ init.ts # Database initialization
65โ”‚ โ””โ”€โ”€ queries.ts # Database query functions
66โ”œโ”€โ”€ api/
67โ”‚ โ”œโ”€โ”€ submitFeedback.ts # HTTP val for feedback submission

bookmarksDatabase

@s3thiโ€ขUpdated 3 months ago

sqLiteDatabase1 file match

@ideofunkโ€ขUpdated 6 months ago