Aircnc is a web application inspired by Airbnb that offers short-term rentals of various property types.
Please see below links to Project Wiki
This project is built with:
- Express
- Sequelize
- PostgreSQL
- React
- Redux
Authenticated and unauthenticated users can view listings on the splash page of Aircnc. You will be able to test the features without sign up by clicking on the "Log In" button, then Sign in with Demo User
You can log in using your credentials or as a demo user.
You can also create your own account by clicking on the "Sign Up" button and filling out the form.
As a signed in user, you can create a new spot/listing by clicking the "Create a new listing" button and filling out the form.
As a signed in user, you can view your listings by clicking on the profile button on the top right. This opens a dropdown menu that has an option to click Your Listings.
As a signed in user, you can edit your listing by clicking the "Edit Listing" button and filling out the form.
As a signed in user, you can edit your listing by clicking the "Delete Listing" button.
As a guest or logged in user, click on a spot/listing to view the spot/listing's details as well as available reviews
As a signed in user, you can write a review. The owner of the spot/location will not be able to write a review for their own spot/listing.
As a signed in user, you can delete a review that you wrote by clicking "Delete Review". Users cannot delete reviews belonging to another person.
As a signed in user, you can click on the drop down on the left hand side to navigate to your bookings as well as delete upcoming bookings.
AS a signed in user, you can navigate to a spot and book the spot by picking from available dates on the calendar.
To run this application locally, you will need Node.js and NPM. This root folder contains a backend and frontend directory.
Clone the project repository in your terminal
https://github.com/coucode/aircnc.git
Inside of the /backend
directory, run the following command in the terminal to set up the necessary Node.js dependencies for running the backend server and database.
npm install
Create a .env file in the /backend
directory based on the .env.example
PORT=
DB_FILE=
JWT_SECRET=
JWT_EXPIRES_IN=
Migrate and seed the database using the following commands. The seeder file is necessary in order to log in as a demo user.
npx dotenv sequelize db:create
npx dotenv sequelize db:migrate
npx dotenv sequelize db:seed:all
Run the server by executing the following command in the /backend
directory.
npm start
Navigate to the /frontend
directory, run the following command to set up the necessary Node.js dependencies and then start the server
npm install
npm start