demo-voter
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://cricks_unmixed4u--2427f57856b711f0a631f69ea79377d9.web.val.run
A simple voting application built for Val Town with React frontend and Hono backend.
- β¨ Create new votes with randomly generated titles
- π Share vote links
- β° Votes expire after 1 hour
- π± Responsive design with TailwindCSS
- Frontend: React with React Query for state management
- Backend: Hono API framework
- Database: SQLite for data persistence
- Styling: TailwindCSS
Votes are automatically generated using random combinations of:
- Netherlands cities (Amsterdam, Rotterdam, Utrecht, etc.)
- B-Corp related terms (sustainable, impact, community, etc.)
- Software terms (platform, solution, application, etc.)
Example: "Amsterdam sustainable platform"
POST /api/votes- Create a new voteGET /api/votes/:id- Get vote by ID
Votes are stored in SQLite and automatically expire after 1 hour.