├── .env.example ├── .eslintrc.json ├── .babelrc ├── public ├── favicon.ico └── vercel.svg ├── assets └── images │ ├── house.jpg │ └── noresult.svg ├── pages ├── api │ └── hello.js ├── _app.js ├── search.js ├── index.js └── property │ └── [id].js ├── .github ├── FUNDING.yml └── dependabot.yml ├── next.config.js ├── components ├── Footer.jsx ├── Layout.jsx ├── Navbar.jsx ├── SearchFilters.jsx ├── ImageScrollBar.jsx └── Property.jsx ├── styles ├── globals.css └── Home.module.css ├── utils ├── fetchApi.js └── filterData.js ├── .gitignore ├── package.json ├── LICENSE.md ├── CONTRIBUTING.md ├── README.md └── CODE_OF_CONDUCT.md /.env.example: -------------------------------------------------------------------------------- 1 | NEXT_APP_RAPID_API_KEY=XXXXXXXXXXXXXXXXXXXXXXXX -------------------------------------------------------------------------------- /.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "next/core-web-vitals" 3 | } 4 | -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["next/babel"], 3 | "plugins": [] 4 | } 5 | -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sanidhyy/real-estate-app/HEAD/public/favicon.ico -------------------------------------------------------------------------------- /assets/images/house.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sanidhyy/real-estate-app/HEAD/assets/images/house.jpg -------------------------------------------------------------------------------- /pages/api/hello.js: -------------------------------------------------------------------------------- 1 | // Next.js API route support: https://nextjs.org/docs/api-routes/introduction 2 | 3 | export default function handler(req, res) { 4 | res.status(200).json({ name: 'John Doe' }) 5 | } 6 | -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: [sanidhyy]# Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] 4 | patreon: sanidhy 5 | custom: https://www.buymeacoffee.com/sanidhy 6 | -------------------------------------------------------------------------------- /next.config.js: -------------------------------------------------------------------------------- 1 | /** @type {import('next').NextConfig} */ 2 | const nextConfig = { 3 | reactStrictMode: true, 4 | images: { 5 | domains: ["bayut-production.s3.eu-central-1.amazonaws.com"], 6 | }, 7 | }; 8 | 9 | module.exports = nextConfig; 10 | -------------------------------------------------------------------------------- /components/Footer.jsx: -------------------------------------------------------------------------------- 1 | import { Box } from "@chakra-ui/react"; 2 | 3 | // Footer 4 | const Footer = () => ( 5 | 12 | {new Date().getFullYear()} Realtor, Inc. 13 | 14 | ); 15 | 16 | export default Footer; 17 | -------------------------------------------------------------------------------- /styles/globals.css: -------------------------------------------------------------------------------- 1 | html, 2 | body { 3 | padding: 0; 4 | margin: 0; 5 | font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, 6 | Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif; 7 | } 8 | 9 | a { 10 | color: inherit; 11 | text-decoration: none; 12 | } 13 | 14 | * { 15 | box-sizing: border-box; 16 | } 17 | -------------------------------------------------------------------------------- /utils/fetchApi.js: -------------------------------------------------------------------------------- 1 | import axios from "axios"; 2 | 3 | // Base URL 4 | export const baseURL = "https://bayut.p.rapidapi.com"; 5 | 6 | // Fetch Data from API 7 | export const fetchApi = async (url) => { 8 | const { data } = await axios.get(url, { 9 | headers: { 10 | "X-RapidAPI-Key": process.env.NEXT_APP_RAPID_API_KEY, 11 | "X-RapidAPI-Host": "bayut.p.rapidapi.com", 12 | }, 13 | }); 14 | 15 | return data; 16 | }; 17 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # next.js 12 | /.next/ 13 | /out/ 14 | 15 | # production 16 | /build 17 | 18 | # misc 19 | .DS_Store 20 | *.pem 21 | 22 | # debug 23 | npm-debug.log* 24 | yarn-debug.log* 25 | yarn-error.log* 26 | .pnpm-debug.log* 27 | 28 | # local env files 29 | .env 30 | .env*.local 31 | 32 | # vercel 33 | .vercel 34 | -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | # To get started with Dependabot version updates, you'll need to specify which 2 | # package ecosystems to update and where the package manifests are located. 3 | # Please see the documentation for all configuration options: 4 | # https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file 5 | 6 | version: 2 7 | updates: 8 | - package-ecosystem: "npm" # See documentation for possible values 9 | directory: "/" # Location of package manifests 10 | schedule: 11 | interval: "weekly" 12 | -------------------------------------------------------------------------------- /components/Layout.jsx: -------------------------------------------------------------------------------- 1 | import Head from "next/head"; 2 | import { Box } from "@chakra-ui/react"; 3 | 4 | import Navbar from "./Navbar"; 5 | import Footer from "./Footer"; 6 | 7 | // Layout 8 | const Layout = ({ children }) => ( 9 | <> 10 | {/* Head Tag */} 11 | 12 | Realtor - Real Estate App 13 | 14 | 15 | {/* Header */} 16 |
17 | 18 |
19 | {/* Main Body */} 20 |
{children}
21 | {/* Footer */} 22 |