• Townie
    AI
  • Blog
  • Docs
  • Pricing
  • We’re hiring!
Log inSign up
Mac4

Mac4

untitled-5794

Public
Like
untitled-5794
Home
Code
5
backend
3
frontend
3
shared
2
README.md
H
main.tsx
Branches
1
Pull requests
Remixes
History
Environment variables
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.
Sign up now
Code
/
Code
/
Search
https://Mac4--6e16acec3fb511f09d8776b3cceeab13.web.val.run
README.md

Saint Benedict Joseph (SBJ) - Apartment Search App

A comprehensive apartment search application that helps users find and save their ideal rental properties.

Features

  • User Authentication: Secure login and registration system
  • Location-based Search: Search apartments by city, state, or zip code
  • Advanced Filters: Filter by price, bedrooms, bathrooms, and amenities
  • Detailed Listings: View photos, descriptions, pricing, and amenities
  • Interactive Map: See apartment locations on an integrated map
  • Favorites System: Save and manage favorite apartment listings
  • Responsive Design: Mobile-first design that works on all devices

Project Structure

β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ database/
β”‚   β”‚   β”œβ”€β”€ migrations.ts    # Database schema setup
β”‚   β”‚   └── queries.ts       # Database query functions
β”‚   β”œβ”€β”€ routes/
β”‚   β”‚   β”œβ”€β”€ auth.ts         # Authentication endpoints
β”‚   β”‚   β”œβ”€β”€ apartments.ts   # Apartment CRUD operations
β”‚   β”‚   β”œβ”€β”€ users.ts        # User management
β”‚   β”‚   └── static.ts       # Static file serving
β”‚   └── index.ts            # Main API entry point
β”œβ”€β”€ frontend/
β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”œβ”€β”€ App.tsx         # Main application component
β”‚   β”‚   β”œβ”€β”€ Auth/           # Authentication components
β”‚   β”‚   β”œβ”€β”€ Search/         # Search and filter components
β”‚   β”‚   β”œβ”€β”€ Listings/       # Apartment listing components
β”‚   β”‚   └── Map/            # Map integration components
β”‚   β”œβ”€β”€ index.html          # Main HTML template
β”‚   β”œβ”€β”€ index.tsx           # Frontend entry point
β”‚   └── style.css           # Application styles
└── shared/
    β”œβ”€β”€ types.ts            # Shared TypeScript interfaces
    └── utils.ts            # Shared utility functions

Technology Stack

  • Backend: Hono.js (lightweight web framework)
  • Database: SQLite (Val Town hosted)
  • Frontend: React with TypeScript
  • Styling: TailwindCSS
  • Maps: Integrated mapping service
  • Authentication: JWT-based auth system

Getting Started

  1. The backend API is accessible at the root URL
  2. All frontend assets are served from /frontend/
  3. The app includes sample apartment data for testing
  4. User authentication is required for saving favorites

API Endpoints

  • POST /api/auth/register - User registration
  • POST /api/auth/login - User login
  • GET /api/apartments/search - Search apartments
  • GET /api/apartments/:id - Get apartment details
  • POST /api/users/favorites - Add/remove favorites
  • GET /api/users/favorites - Get user favorites

Environment Variables

No external API keys required - the app uses mock data and built-in services.

HTTP
  • index.ts
    Mac4--54…13.web.val.run
  • App.tsx
    Mac4--6e…13.web.val.run
  • index.tsx
    Mac4--60…13.web.val.run
  • main.tsx
    Mac4--7b…13.web.val.run
Code
backendfrontendsharedREADME.md
H
main.tsx
FeaturesVersion controlCode intelligenceCLI
Use cases
TeamsAI agentsSlackGTM
DocsShowcaseTemplatesNewestTrendingAPI examplesNPM packages
PricingNewsletterBlogAboutCareers
We’re hiring!
Brandhi@val.townStatus
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Terms of usePrivacy policyAbuse contact
Β© 2025 Val Town, Inc.