Unlock the value of your unwanted household items with Nookly: Recycle Home Items.
Nookly is an application that follows the MVC paradigm in its architectural structure, using Handlebars.js as the templating language, Sequelize as the ORM, and the express-session npm package for authentication.
Our platform connects sellers with buyers that are passionate about sustainability and creating a seamless marketplace for recycling within your community. Join us in reshaping the way we think about decluttering!
This project defines 3 Sequelize models and utilizes the express-session
model:
User
Listing
Comment
The database is mapped according to the following schema:
There is no installation necessary as this application is deployed to Heroku. You can visit the deployed application here and try it out!
If you would like to run the application locally, use the following steps:
- Clone this repository to your local machine. (For reference, visit the Cloning a Repository GitHub Docs article.)
- Run
npm install
in your CLI to download the npm package dependencies. - Run
mysql -uroot -p
in your CLI and log into MySQL. - Run
source db/schema.sql
to create the database on your local machine. - Exit out of MySQL by running
exit
. - Run
npm run seed
in the root directory to seed the database. - Run
npm run start
to sync the Sequelize models to the MySQL database and start the server. - Open
http://localhost:3001
in your local browser.
This project requires the following npm package dependencies:
- aws-sdk-js-v3
- bcrypt
- connect-session-sequelize
- dotenv
- express
- express-handlebars
- express-session
- multer
- multer-s3
- mysql2
- sequelize
The animation gif below demonstrates the app's functionality:
- The user will see listings on the Home page that are not sold yet
- The user will be able to click each listing to expand it and view comments
- Once the user is logged in, they will be able to add comments of their own under listings
- Each listing will have a comment count displayed to show the user how much attention the listing is getting
- Once logged in, the user will be able to access their profile, where listings they have created will appear
- Clicking the 'New Listing' button will render a card that prompts the user to enter information about their new listing, as well as an image
- Once the listing is created, the user may click on each lisiting in their profile to update or delete it
- If the user marks the listing as sold, there will be a 'SOLD!' indicator on the corresponding post
- Once a listing is marked sold, it will be removed from the Home page
- The user will have the option to login if they already have an account, or press the
Sign Up Instead
to create an account - Once logged in, the user will be redirected to their Profile page
- They will then be able to create new listings in the Profile page and add comments in the home page
- The user will be alerted with an error if their credentials are incorrect
- The user will be able to create an account by filling all fields for the username, email, and password
- If the user already has an account, they can press the
Login Instead
button to be redirected to the login page - Sign up will fail if the user doesn't enter a valid email or a password over 8 charaters long
No test suites have been written for this application. The API routes were tested locally during development with the Insomnia development platform.
Please refer to the Installation section if you are interested in running and testing the application locally.
To make contributions to this project:
- Fork the repository
- Make some commits to improve the application
- Open a Pull Request on GitHub
- From there, we can discuss your changes and merge the pull request once your contributions have been approved!
This GitHub repository is licensed under the MIT license. Please refer to the license documentation here.
This project was developed by the following contributors:
For any related questions, please contact me via email at [email protected].