A responsive React TypeScript application that replicates a real estate listing form with validation.
- Complete real estate form with field validation
- Responsive design for all device sizes
- Interactive form elements (dropdowns, button groups)
- Image upload and reordering with cover image functionality
- Location selection with state, city, and neighborhood dropdowns
- Form validation with error messages and visual indicators
This project is configured for easy deployment on Vercel.
-
Install the Vercel CLI:
npm install -g vercel -
Login to Vercel:
vercel login -
Deploy the project:
vercel
- Push the code to your GitHub repository.
- Import the project on Vercel dashboard: https://vercel.com/new
- Connect your GitHub repository
- Configure the project:
- Framework Preset: Vite
- Build Command:
npm run build - Output Directory:
dist
- Click "Deploy" and Vercel will automatically build and deploy your application.
-
Install dependencies:
npm install -
Start development server:
npm run dev -
Build for production:
npm run build
- React 18
- TypeScript
- Styled Components
- Vite
- Node.js
- npm or yarn
- Clone the repository:
git clone <repository-url>
- Navigate to the project directory:
cd olx-form-clone
- Install dependencies:
npm install
or
yarn install
- Start the development server:
npm run dev
or
yarn dev
- Open your browser and visit
http://localhost:5173
src/components/- Contains all the form componentsPostForm.tsx- Main form container componentCategorySelector.tsx- Grid of category optionsAttributeSection.tsx- Dynamic fields based on categoryDescriptionSection.tsx- Title and description inputsPriceSection.tsx- Price input with currency symbolPhotoUploader.tsx- Photo upload and preview functionalityLocationSection.tsx- Location search with autocomplete
This is a frontend-only implementation focused on the UI/UX of the OLX form. In a real-world scenario, you would integrate this with backend APIs for:
- Saving form data
- Uploading and storing images
- Address/location verification
- User authentication
MIT