JSFiddle - React, Tailwind, and code Playground

HTML

<!DOCTYPE html>
<html>
<head>
  <style>
input, label { line-height: 1.5em; }
</style>
  <script src="http://code.jquery.com/jquery-latest.js"></script>
</head>
<body>
  
<form>
  <div>
    <input type="checkbox" name="fruit" value="1" id="orange">
    <label for="orange">orange</label>
  </div>
  <div>
    <input type="checkbox" name="fruit" value="2" id="apple">
    <label for="apple">apple</label>
  </div>
  <div>
    <input type="checkbox" name="fruit" value="3" id="banana">
    <label for="banana">banana</label>
  </div>
  <textarea id="log">
   </textarea>
</form>

<script>

</script>

</body>
</html>

JavaScript

$("input").click(function() {
  $("#log").html( $(":checked").val() + " is checked!" );
});