From 2a38544dd1fd5afbb633e7e9cc3cd7ab7a1643a1 Mon Sep 17 00:00:00 2001 From: mraysu Date: Sun, 5 Jan 2025 20:26:15 -0800 Subject: [PATCH] Updated README --- README.md | 43 ++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ca25ed8..7d45447 100644 --- a/README.md +++ b/README.md @@ -1 +1,42 @@ -# HomeWork-Website-Revamp \ No newline at end of file +# [HomeWork-Website-Revamp](https://www.homework-sd.org/) + +A website revamp for HoMEwork, an organization focused on providing community outreach for post-incarcerated inviduals. This website aims to declutter the original website while adding modular features that allow the website to grow with the organization. These features include resources for future and past events, contacting and donating pipelines, and a consistently updating news page. + +This website adds an admin portal to facilitate website integration into organization operations, including a custom calendar with attendance tracking and photo and document uploading pipelines. + +## Setup + +### Tools +Before starting development, make sure you have these tools installed: + +- [Node.js](https://nodejs.org/en) - this is our JS runtime +- [Npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) - this is our package manager +- [Postman](https://www.postman.com/downloads/) - helpful for testing API routes +- [MongoDB Community](https://www.mongodb.com/docs/manual/administration/install-community/) - necessary if you want to run database locally + +### Environment +To define and manage environment variables, make sure to maintain `.env` files in both the `frontend` and `backend` directories. Ensure that `.env` is specified in your root `.gitignore` file to prevent pushing secrets. This should already be the case, but the secret scanner hook will check for this if something gets changed + +Add the `.env.frontend` and `.env.backend` from the project google drive to their respective directories in your local branch. + +### Backend + +1. `cd backend` +2. Run `npm install` to install all dependencies +3. If running the database locally, make sure to [start mongod](https://www.mongodb.com/docs/manual/tutorial/manage-mongodb-processes/#start-mongod-processes) +4. `npm run start` to start the backend + +If this works properly you should see a message in the terminal saying `> Listening on port 4000` + +### Frontend + +1. `cd frontend` +2. Run `npm install` to install all dependencies +3. Run `npm run dev` to start development server +4. Server is started on port 3000. Follow this [url](http://localhost:3000) and you should see the development page. + +## Linting +Run these commands in the `backend` or `frontend` directories for linting and formating. Be sure to run these commands before pushing to github. + +- `npm run lint-fix` - fixes all auto-fixable lint errors and reformats code +- `npm run lint-check` - check all lint errors or code style issues without modifying any files