This project demonstrates the integration of a simple React application with a MySQL database via a Node.js/Express.js server. It shows how to effectively implement and manage a server solution for applications using ReactJS and MySQL. This project is ideal for developers who want to gain hands-on experience with these technologies and develop their own applications.
- React.js: Frontend framework used for building user interfaces. Ensures efficient rendering of components.
- Vite: Next generation frontend tooling, used here for building and serving the React application with optimizations like fast hot module replacement.
- Node.js/Express.js: The backend is powered by Express running on Node.js, which simplifies the server creation and routing.
- MySQL: Used as the database to store application data, accessed from the Node.js application.
- Nodemon: Utility that monitors for any changes in your source and automatically restarts your server, used in development.
- CORS: Node.js package for providing a Connect/Express middleware that can be used to enable CORS with various options.
- ESLint: JavaScript linter used in the frontend for identifying and reporting on patterns found in ECMAScript/JavaScript code, helping to make code more consistent and avoiding bugs.
Before getting started with this project, make sure you have Node.js, MySQL, and optionally Yarn or npm (which comes with Node.js) installed on your system.
Also you can add also an external MySQL Database
Follow these steps to install and run the project on your local system:
- Clone the repository:
git clone https://github.com/pottz91/React-MYSQL.git cd your-project/backend npm install cd ../frontend npm install
- This is how you start, frontEnd and Backend:
cd Backend npm start cd frontEnd npm run dev
