Element Selector in jquery

jQuery element selector choose elements based on the element name.

Example:-

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script>
$(document).ready(function(){
  $("button").click(function(){
    $("p").hide();
  });
});
</script>
</head>
<body>
<p>Paragraph.</p>

<button>button</button>

</body>
</html>

OUTPUT:-

When we click the button, p element will be hide.

Thanks

Element Selector in jqueryexpoundsofttechsolution What is GMT?