Sure! Here's a basic README.md file for your AI Disaster Management App (Disaster Guard) project. It covers setup instructions for both backend and frontend, and can be expanded as needed:
``
An AI-powered platform to report, monitor, and manage disaster-related data in real-time. This application consists of a Node.js + Express backend, a Vite + React frontend, and MongoDB for the database.
ai-disaster-management/
├── backend/
│ ├── config/
│ ├── middleware/
│ ├── models/
│ ├── routes/
│ ├── .env
│ └── server.js
├── frontend/
│ ├── public/
│ ├── src/
│ └── vite.config.js
└── README.md
cd backendnpm installCreate a .env file in the backend/ directory:
PORT=5000
NODE_ENV=development
MONGODB_URI=your-mongodb-uri-herenpm startBy default, the server runs on http://localhost:5000
cd ../frontendnpm installVITE_API_URL=http://localhost:5000/apinpm run devnpm run buildThis will create the dist/ folder, which will be used by the backend to serve the frontend in production.
Ensure your backend is set to serve static files in production:
// Inside backend/server.js
if (process.env.NODE_ENV === 'production') {
app.use(express.static(path.join(__dirname, '../frontend/dist')));
app.get('*', (req, res) => {
res.sendFile(path.resolve(__dirname, '../frontend/dist', 'index.html'));
});
}- Frontend: React, Vite, Tailwind CSS,Next js
- Backend: Node.js, Express.js
- Database: MongoDB
- Other Tools: Dotenv, CORS, Mongoose
- 🔐 User authentication (login/register)
⚠️ Real-time disaster alert reporting- 📍 Resource tracking (supplies, shelters, etc.)
- 🛰️ Integration with external disaster-related APIs
- 📊 Admin dashboard (optional)
Made by D.ROHITH KUMAR
This project is licensed under the MIT License.
---
Let me know if you want to add screenshots, a contributing section, or deployment instructions for Render/Netlify/Vercel.