JSFiddle - React, Tailwind, and code Playground
HTML
<form id="form1">
<input type="text" value="" />
<input type="radio" name="gender" value="m" />
<input type="radio" name="gender" value="f" />
</form>
<button type="button" id="button1">Show HTML</button>
JavaScript
$('#button1').click(
function(){
alert($('#form1').html());
}
);