testmar24
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data β all from the browser, and deployed in milliseconds.
index.ts
https://charmaine--d36d996a08b611f08c12569c3dd06744.web.val.run
A simple todo list application built for Val Town using React, Hono, and SQLite.
- Create, read, update, and delete todos
- Mark todos as completed
- Responsive design with Tailwind CSS
- Optimistic UI updates for a smooth user experience
- Persistent storage using Val Town's SQLite
βββ backend/
β βββ database/
β β βββ queries.ts # SQLite database operations
β βββ index.ts # Hono API server
βββ frontend/
β βββ components/
β β βββ App.tsx # Main React component
β βββ index.html # HTML template
β βββ index.tsx # React entry point
βββ shared/
βββ types.ts # Shared TypeScript interfaces
- Uses Hono as the web framework
- Provides RESTful API endpoints for todo operations
- Serves the frontend static files
- Uses Val Town's SQLite for data persistence
- Built with React
- Uses Tailwind CSS for styling
- Communicates with the backend API
- Implements optimistic UI updates
GET /api/todos- Get all todosGET /api/todos/:id- Get a specific todoPOST /api/todos- Create a new todoPATCH /api/todos/:id- Update a todoDELETE /api/todos/:id- Delete a todo
- Fork this project in Val Town
- The app will automatically create its database table on first run
- Access the app through your Val Town URL