This folder contains examples of full-stack web applications built using React for the frontend and Express.js for the backend. These examples demonstrate how to integrate a React client with an Express server to create dynamic and interactive web applications.
- Description: A web app where users can leave messages in a guestbook. The frontend is built with React, and the backend uses Express to handle API requests and store messages.
- How to Run:
- Navigate to the
guestbook-appfolder. - Start the backend server:
- Navigate to the
serverfolder. - Install dependencies:
npm install
- Start the server:
node index.js
- Navigate to the
- Start the frontend client:
- Navigate to the
clientfolder. - Install dependencies:
npm install
- Start the React development server:
npm start
- Navigate to the
- Open your browser and navigate to
http://localhost:3000.
- Navigate to the
- Description: A web app that allows users to browse and adopt pets. The React frontend communicates with the Express backend to fetch and manage pet data.
- How to Run:
- Navigate to the
pet-adoption-appfolder. - Start the backend server:
- Navigate to the
serverfolder. - Install dependencies:
npm install
- Start the server:
node index.js
- Navigate to the
- Start the frontend client:
- Navigate to the
clientfolder. - Install dependencies:
npm install
- Start the React development server:
npm start
- Navigate to the
- Open your browser and navigate to
http://localhost:3000.
- Navigate to the
- The frontend React apps are bootstrapped with Create React App.
- The backend Express servers handle API requests and serve static files.
- Static assets for the frontend are located in the
publicfolder of each React app. - View templates for the backend (if any) are located in the
viewsfolder of each server.