125 <h3 className="font-semibold text-gray-900 dark:text-white mb-2">SQLite</h3>
126 <p className="text-sm text-gray-600 dark:text-gray-400">
127 Query and manage your databases
128 </p>
129 </div>
130 </p>
131 <p className="text-sm text-gray-600 dark:text-gray-400">
132 Manage blobs, emails, profiles, SQLite databases, and vals from one place
133 </p>
134 </div>
1# Val Town Dashboard
2
3A dashboard application for managing Val Town resources including blobs, emails, profiles, SQLite databases, and vals.
4
5## Project Structure
36- **Email Management**: Handle Val Town email functionality
37- **Profile Management**: Manage Val Town user profiles
38- **SQLite Management**: Interact with Val Town SQLite databases
39- **Vals Management**: Manage Val Town vals (functions)
40- **Settings**: User authentication and preferences
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { castVote, getVoteResults, hasUserVoted, getUserVote } from "../database/queries.ts";
3import { CANDIDATES } from "../../shared/types.ts";
4
22 )`);
23
24 console.log('Database migrations completed');
25}
26
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 { getVoteResults, getChatMessages } from "./database/queries.ts";
5import votes from "./routes/votes.ts";
6import chat from "./routes/chat.ts";
13});
14
15// Initialize database on startup
16await runMigrations();
17
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { addChatMessage, getChatMessages, getRecentChatMessages } from "../database/queries.ts";
3
4const chat = new Hono();
1// val type=script
2import { db } from "https://esm.town/v/Sarax201.MyProgress.Database.db.achievements";
3
4export function addAchievement(data: {
1// val type=http
2import { Hono } from "https://deno.land/x/hono/mod.ts";
3import { addAchievement } from "https://esm.town/v/Sarax201.MyProgress.Database.addAchievement";
4import { getAchievements } from "https://esm.town/v/Sarax201.MyProgress.Database.getAchievements";
5
6const app = new Hono();
1// val type=script
2import { Database } from "https://deno.land/x/sqlite/mod.ts";
3
4export const db = new Database();
5
6db.execute(`