13 payFine,
14 createAuditLog
15} from "../database/queries.ts";
16import type { IssueBookRequest, ReturnBookRequest } from "../../shared/types.ts";
17
10 deleteBook,
11 createAuditLog
12} from "../database/queries.ts";
13import type { Book, BookSearchParams } from "../../shared/types.ts";
14
1import { Hono } from "https://esm.sh/hono@3.11.7";
2import { getCookie, setCookie, deleteCookie } from "https://esm.sh/hono@3.11.7/cookie";
3import { getUserByEmail, createUser, createAuditLog } from "../database/queries.ts";
4import type { LoginRequest, RegisterRequest } from "../../shared/types.ts";
5
2
3export async function runMigrations() {
4 console.log("Running database migrations...");
5
6 // Users table
165 ]);
166 }
167 console.log("Sample books added to the database");
168 }
169
170 console.log("Database migrations completed successfully");
171}
17- Categorize by genre, subject, or level
18- Barcode/QR scanning for fast entry
19- Integration with ISBN databases for autofill
20
21### Search & Catalog Browsing
45- Backend: Hono.js with TypeScript
46- Frontend: React with TypeScript
47- Database: SQLite
48- Styling: TailwindCSS
49
51```
52โโโ backend/
53โ โโโ database/
54โ โ โโโ migrations.ts
55โ โ โโโ queries.ts
74
75## Getting Started
761. The system will automatically create the database tables on first run
772. Default admin user will be created (admin@library.com / admin123)
783. Access the system via the HTTP endpoint
10- โ
Clear all completed todos
11- โ
Responsive design with TailwindCSS
12- โ
SQLite database for persistence
13- โ
RESTful API
14
17```
18โโโ backend/
19โ โโโ database/
20โ โ โโโ migrations.ts # Database schema
21โ โ โโโ queries.ts # Database operations
22โ โโโ index.ts # Main API server
23โโโ frontend/
2import { cors } from "https://esm.sh/hono@4.0.10/cors";
3import { readFile, serveFile } from "https://esm.town/v/std/utils@85-main/index.ts";
4import { createTodoTable } from "./database/migrations.ts";
5import { getAllTodos, getTodoById, createTodo, updateTodo, deleteTodo } from "./database/queries.ts";
6import type { CreateTodoRequest, UpdateTodoRequest } from "../shared/types.ts";
7
8const app = new Hono();
9
10// Initialize database
11await createTodoTable();
12
40 `);
41
42 console.log('Database migrations completed');
43}
44
8 saveTourProgress,
9 getTourProgress
10} from "../database/queries.ts";
11import type { Itinerary, ItineraryRequest, TourProgress, ApiResponse } from "../../shared/types.ts";
12
16```
17โโโ backend/
18โ โโโ database/
19โ โ โโโ migrations.ts # Database schema
20โ โ โโโ queries.ts # Database operations
21โ โโโ routes/
22โ โ โโโ expenses.ts # Expense API routes
37## Tech Stack
38
39- **Backend**: Hono.js with SQLite database
40- **Frontend**: React with TypeScript
41- **Styling**: TailwindCSS with custom gradients
90- โ
Delete expenses with confirmation
91- โ
Responsive design for mobile and desktop
92- โ
SQLite database with proper indexing
93- โ
RESTful API endpoints
94