JSFiddle - React, Tailwind, and code Playground

by techiedelight

HTML

<label for="name">Email address:</label>
<input type="email" id="name" placeholder="Enter email">

JavaScript

var elementType = document.getElementById("name").type;
alert(elementType);