JSFiddle - React, Tailwind, and code Playground

by toshi_n

HTML

<html>

<head>

<style>

#test1{
 background-color:red;
 width:100px;
 height:100px;
}


#test2{
 background-color:blue;
 width:100px;
 height:100px;
}
</style>

<script>



var Zero = function(ele){

  var eve = ele.getAttribute("id")
  alert("idは" + eve + "だよ!")
  return eve;

}

console.log(Zero())


</script>

</head>

<body>
<div id="test1" onclick=Zero(this)></div>
<div id="test2" onclick=Zero(this)></div>
</body>

</html>