Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
guruakashsm authored Feb 8, 2024
1 parent c4dba6e commit 4c7a8b6
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1757,6 +1757,7 @@ <h3 class="h3 form-title">Contact Form</h3>
<script type="module">
// Import the functions you need from the SDKs you need
import { initializeApp } from "https://www.gstatic.com/firebasejs/10.8.0/firebase-app.js";
import { getMessaging, getToken } from "firebase/messaging";
// TODO: Add SDKs for Firebase products that you want to use
// https://firebase.google.com/docs/web/setup#available-libraries

Expand All @@ -1773,7 +1774,16 @@ <h3 class="h3 form-title">Contact Form</h3>
// Initialize Firebase
const app = initializeApp(firebaseConfig);
const messaging = getMessaging(app);
const token = getToken(messaging, {vapidKey: "BCrJwTk22v4foZjvCmawjXoagm6wQLmZI8LXlFlXMz5sg9mmRgssPWbD7y4QfTLZE4zJ4y9h2lCac1pFhYFs6sk"});

//onst token = getToken(messaging, {vapidKey: "BCrJwTk22v4foZjvCmawjXoagm6wQLmZI8LXlFlXMz5sg9mmRgssPWbD7y4QfTLZE4zJ4y9h2lCac1pFhYFs6sk"});





const messaging1 = getMessaging();
// Add the public key generated from the console here.
var token=getToken(messaging1, {vapidKey: "BCrJwTk22v4foZjvCmawjXoagm6wQLmZI8LXlFlXMz5sg9mmRgssPWbD7y4QfTLZE4zJ4y9h2lCac1pFhYFs6sk"});
console.log(token);
</script>
<script register-worker.js></script>
Expand Down

0 comments on commit 4c7a8b6

Please sign in to comment.