Public
Like
Blogged
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://David_Navi--0630a7d23fbe11f0b6c376b3cceeab13.web.val.run
A social blogging platform where users can share their daily experiences, thoughts, and stories with the community.
- User Profiles: Create and customize personal profiles
- Blog Posts: Write and publish daily blog posts with rich text
- Social Interactions: Like, comment, and share posts
- Feed: Browse post summaries on the main page
- Full Post View: Click to read complete posts
- Responsive Design: Works on desktop and mobile
βββ backend/
β βββ database/
β β βββ migrations.ts # Database schema setup
β β βββ queries.ts # Database query functions
β βββ routes/
β β βββ auth.ts # Authentication routes
β β βββ posts.ts # Post CRUD operations
β β βββ users.ts # User profile operations
β β βββ static.ts # Static file serving
β βββ index.ts # Main Hono app entry point
βββ frontend/
β βββ components/
β β βββ App.tsx # Main React app
β β βββ PostCard.tsx # Post summary component
β β βββ PostDetail.tsx # Full post view
β β βββ UserProfile.tsx # User profile component
β β βββ CreatePost.tsx # Post creation form
β βββ index.html # Main HTML template
β βββ index.tsx # Frontend entry point
β βββ style.css # Custom styles
βββ shared/
β βββ types.ts # Shared TypeScript types
βββ README.md
- Backend: Hono (TypeScript API framework)
- Frontend: React 18.2.0 with TypeScript
- Database: SQLite
- Styling: TailwindCSS
- Storage: Val Town Blob for user avatars
- The backend automatically sets up the database on first run
- Visit the main page to start browsing posts
- Create an account to start posting and interacting
- Customize your profile and start sharing your daily experiences
GET /
- Main feed pageGET /api/posts
- Get all posts (with pagination)GET /api/posts/:id
- Get specific post with commentsPOST /api/posts
- Create new postPOST /api/posts/:id/like
- Like/unlike a postPOST /api/posts/:id/comments
- Add comment to postGET /api/users/:id
- Get user profilePOST /api/users
- Create/update user profile