The City Management System frontend is a React-based application that provides a user interface for managing city and electricity/water supply data.
- React: Frontend library for building user interfaces.
- React Router DOM: For handling routing and navigation.
- Material-UI: For UI components and styling.
- Chart.js: For rendering charts and graphs.
- Axios: For making HTTP requests.
- Tailwind CSS: For utility-first CSS framework (if used in
App.css
).
git clone git@github.com:nhpquy/city-management-fe.git
cd city-management-fe
Ensure you have Node.js and npm installed. Run the following command to install the required dependencies:
npm install
yarn
Create a .env
file in the root of your project if it doesn't already exist. Add any required environment variables. For example:
REACT_APP_API_URL=http://localhost:8080/api
Make sure to replace the REACT_APP_API_URL
with your backend server URL.
Run the following command to start the development server:
npm start
yarn start
This will start the React development server and open the application in your default web browser. The app will be available at http://localhost:3000.
To create a production build of your application, run:
npm run build
yarn run build
The build files will be generated in the build
directory. You can deploy these files to your production server.
To run tests, use:
npm test
This will start the test runner and execute your test cases.