React Component Nesting and Reusability Explained – A Beginner's Guide 2026

Image
1. Introduction to React Component Nesting and Reusability React JS is a popular JavaScript library used to create interactive and user-friendly web applications. One of the most useful concepts in React development is component-based architecture. Instead of writing an entire website inside one large file, developers divide the user interface into smaller and manageable parts called components. Two important concepts in this approach are component nesting and component reusability. Component nesting means placing one React component inside another component to build a complete user interface. For example, a website page may contain a header, navigation bar, sidebar, content section, and footer. Each section can be developed as a separate component and combined inside a main component. Component reusability means creating a component once and using it multiple times in different parts of an application. For example, the same button, product card, or navigation menu can be reused withou...

how to create a contact form with html and CSS


 

Creating Sample Contact Us Form Using HTML

           CONTACT  FORM


contact form


PROGRAM :CODE

CONTACT FROM

what is the contact form?

A page on a website that allows users to contact the website owner. This page contains fields for your name, address and language. On most blog sites, this includes email and postal addresses; however, the contact form provides a direct and easy way for users to ask questions on the blog site..


<!DOCTYPE html>  
<html>  
<head>  
<meta name="viewport" content="
width=device-width, initial-scale=1">  

<link href ="https ://fonts.googleapis.com
/css?family =Raleway " rel= " stylesheet ">
<style>  
body{  
  font-family: Calibri, Helvetica, sans-serf;  
 
}  
.container {  
    padding: 50px;  
  background-color : skyblue ;  
}  
 
input[type=text], input[type=password],textarea {  
  width: 100%;  
  padding: 15px;  
  margin: 5px 0 22px 0;  
  display: inline-block;  
  border: none;  
  background: #f1f1f1;  
}  
input[type=text]:focus,input[type=password]
:focus {  
  background-color: orange;  
  outline: none;  
}  
 div {  
            padding: 10px 0;  
         }  
hr {  
  border: 1px solid #f1f1f1;  
  margin-bottom: 25px;  
}  
.registerbtn {  
  background-color: #4CAF50;  
  color: white;  
  padding: 16px 20px;  
  margin: 8px 0;  
  border: none;  
  cursor: pointer;  
  width: 100%;  
  opacity: 0.9;  
}  
.registerbtn:hover {  
  opacity: 1;  
}  

</style>  
</head>  
<body>  
<form>
</br>
</br>
<!--<marquee    bgcolor ="Red" >
Registertion Now </Marquee >-->
</br>
</br>
  <div class="container">  
  <center>  <h1>  Contact  Us </h1> </center>  
  <hr>  
  <label> Firstname </label>  
<input type="text" name="firstname"
placeholder= "Firstname" size="15" required />  
<label> Middlename: </label>  
<input type="text" name="product  name "
placeholder="Middlename" size="15" required />  
<label> Lastname: </label>    
<input type="text" name="lastname"
placeholder="Lastname" size="15"required />  
<div>  
<label>  
<div>  
<label>  
Gender :  
</label><br>  
<input type="radio" value="Male"
name="gender" checked > Male  
<input type="radio" value="Female"
name="gender"> Female  
<input type="radio" value="Other"
name="gender"> Other  
</div>  
<label>  
Phone :  
</label>  
<input type="text" name"phone"
placeholder=""  value="+91" size="2"/>  
<input type="text" name="phone" placeholder="
retype phone no." size="10"/ required>  
</br>

State   :  
<input type ="text " name = "state "
placeholder = "state ">
</br>
</br>

 <label for="email"><b>Email</b></label>  
 <input type="text" placeholder="Enter Email"
name="email" required>  
 
    <label for="psw"><b>Password</b></label>  
    <input type="password" placeholder=
"Enter Password" name="psw" required>  
 
    <label for="psw-repeat"><b>Re-type
Password</b></label>  
    <input type="password" placeholder=
"Retype Password" name="psw-repeat" required>  
    <button type="submit" class="registerbtn">
Submit </button>    
</form>  
</body>  
</html>  

Related Post :-

👍👍

html button tag

css introduction

html color tag

Comments

Popular posts from this blog

CSS Text Color Explained with Syntax and HTML Examples

CSS Outline Offset Property with Practical Examples

Learn CSS text-decoration-color Property in Simple Words with Examples