JSFiddle - React, Tailwind, and code Playground
by qustosh
HTML
<div class="main">
<input type="text" class="answer" /><br>
<button type="button" >Click Me!</button>
</div>
CSS
.main{width:300px;margin:auto;text-align:center;}
JavaScript
b = jQuery("button").eq(0);
b.click(function(){
var v = jQuery(".answer").eq(0).val();
});