I am using gitpod to test the push notifications that I have setup in DJnago using firebase. Everything went well but in the end the request permission dialog box didn't appear. I am not sure what is the cause.
The link that I followed is this one:
https://blog.hipolabs.com/testing-push-notifications-locally-with-firebase-ef052531af03
It was supposed to come like this:
But in mine it appears like this:
The request permission button is missing on mine. I have done several attempts but the same result. The index.html file looks like this:
function requestPermission() {
console.log('Requesting permission...');
Notification.requestPermission().then((permission) => {
if (permission === 'granted') {
console.log('Notification permission granted.');
// TODO(developer): Retrieve a registration token for use with FCM.
// In many cases once an app has been granted notification permission,
// it should update its UI reflecting this.
resetUI();
} else {
console.log('Unable to get permission to notify.');
}
});
}