permissions-policy-geolocation.html (270B)
1 <script> 2 const type = "availability-result"; 3 navigator.geolocation.getCurrentPosition( 4 () => { 5 window.parent.postMessage({ type, enabled: true }, "*"); 6 }, 7 () => { 8 window.parent.postMessage({ type, enabled: false }, "*"); 9 } 10 ); 11 </script>