Check out example codes for "how to display date in dd-mmm-yyyy format in html for type="date"". It will help you in understanding the concepts better.

Code Example 1

<!DOCTYPE html> 
<html> 
  
<head> 
    <title> 
        How to get input type date 
        in dd-mm-yyyy format ? 
    </title> 
      
    <style> 
        body { 
            text-align: center; 
        } 
        h1 { 
            color: green; 
        } 
    </style> 
</head> 
  
<body> 
    <h1>GeeksforGeeks</h1> 
      
    <h3> 
        Get input date in 
        dd-mm-yyyy format 
    </h3> 
      
    <label for="Date of Birth"> 
        Enter the Date: 
        <input type="date" name="date"> 
    </label> 
</body> 
  
</html>

Learn ReactJs, React Native from akashmittal.com