This is a basic React project that demonstrates the usage of props and state to create a simple CONTACT US form. Users can fill in their information in the form, and the details will be displayed on the site using React's props and state.
Make sure you have Node.js and npm (Node Package Manager) installed on your machine.
-
Clone the repository or download the project files.
-
Navigate to the project directory using the terminal.
-
Install the project dependencies by running the following command:
npm install
Running the Application
To run the application, use the following command:
bash
Copy code
npm start
The application will start, and you can access it by visiting http://localhost:3000 in your web browser. (Might be a diff port based on user)
Features
The CONTACT US form allows users to enter their name, email, and message.
When the user submits the form, the entered information will be displayed on the site using React's props and state.
ContactForm.js: This component renders the CONTACT US form and handles form submissions using React's setState.
DisplayInfo.js: This component receives the form data as props and displays it on the site.
App.js: The main application file that renders the ContactForm and DisplayInfo components.
index.js: The entry point of the application.
Technologies Used
React: A JavaScript library for building user interfaces.
React Props: Used to pass data from parent components to child components.
React State: Used to manage the state of the form and update the site with the submitted information.
CSS: Basic styling for the components.
Contributing
If you want to contribute to this project, feel free to create a pull request. All contributions are welcome!
License
This project is licensed under the MIT License.