<!DOCTYPE html>
<html lang="en-US">
<body>
<h1>CSS pointer-events Property</h1>
<a href="#">Hover me before and after clicking on the button.</a>
<button onclick="myFunction()">Click Me</button>
<script>
var x = document.getElementsByTagName("a")[0];
function myFunction(){
x.style.pointerEvents = "none";
}
</script>
<p><strong>Note</strong>: Click on the button to change the 'pointer-events' from auto to none.</p> </body>
</html>