A full-stack hospital management system built using MongoDB, Express.js, React, and Node.js.
Before running the project, ensure you have the following installed:
- Node.js (Download from nodejs.org)
- Git
git clone https://github.com/SimonShangpliang/HMIS.git
cd HMIScd backend
npm installcd ../frontend
npm installCreate a .env file inside the backend folder and add:
PORT=5000
MONGO_URI=your_mongodb_connection_string
cd backend
npm run devcd frontend
npm run devThe frontend should now be running on http://localhost:5173, and the backend should be on http://localhost:5000.
HMIS/
│── backend/ # Express.js backend
│ ├── server.js
│ ├── models/
│ ├── routes/
│ ├── controllers/
│ ├── .env
│ └── package.json
│
│── frontend/ # React (Vite) frontend
│ ├── src/
│ ├── public/
│ ├── vite.config.js
│ └── package.json
│
└── README.md # Project documentation
- Fork the repo
- Create a new branch (
git checkout -b feature-branch) - Commit changes (
git commit -m "Added new feature") - Push (
git push origin feature-branch) - Submit a Pull Request
If you want to pull changes from the main repo to keep your fork updated before making new changes, follow these steps:
Before making new changes, you should sync your fork with the latest updates from the main repository.
You only need to do this once after forking:
git remote add upstream https://github.com/SimonShangpliang/HMIS.gitgit fetch upstreamgit checkout maingit merge upstream/mainor, to rebase for a cleaner history:
git rebase upstream/maingit push origin mainNow your fork is in sync with the main repo! 🚀
If you are starting a new feature branch, always sync your fork before creating the branch:
git checkout main
git pull upstream main
git checkout -b new-featureIf you don’t want to use the terminal, you can:
- Go to your fork on GitHub.
- Click "Fetch upstream" (found above the file list).
- Click "Merge" to update your fork.