From the course: JavaScript: Progressive Web Applications
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Adding Firebase Cloud Messaging to the project - JavaScript Tutorial
From the course: JavaScript: Progressive Web Applications
Adding Firebase Cloud Messaging to the project
- [Instructor] Before we can subscribe users and send push messages, we'll need to get a message service involved. Google provides the Firebase cloud messaging tool as its messaging service. To send push messages, we'll need to create a project within Firebase, and gain access to the unique identifier for our project. So let's log into the Firebase console at console.firebase.google.com. To get started, click on Add Project. Give your project a name. I'll just call this LinkedInLearning PWA, and then click on the Control or Controller terms and accept them, and click on Create Project. Once the project is created, click on Continue to open it in the console. Then tap the Settings icon in the top left corner, it's the one that looks like a gear, and choose Project Settings. Click on the Cloud Messaging tab, and there you'll see your server key and sender ID. We need to copy the sender ID and paste it into our manifest file. So you can hover your mouse over the Sender ID field and…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
-
(Locked)
Introduction to notifications2m 21s
-
(Locked)
Requesting permission to show notifications5m 26s
-
(Locked)
Displaying a notification4m 50s
-
(Locked)
Adding data to a notification4m 36s
-
(Locked)
Closing a notification3m 33s
-
(Locked)
Handling the notification click event11m 25s
-
(Locked)
Push messaging overview1m 24s
-
(Locked)
Adding Firebase Cloud Messaging to the project2m 15s
-
(Locked)
Subscribing to push messaging6m
-
(Locked)
Handling push notifications3m 14s
-
(Locked)
Sending a tickle using cURL4m 57s
-
(Locked)
Sending data in a push message2m 9s
-
(Locked)
Installing Mozilla's Web Push library2m 51s
-
(Locked)
Modifying the push event handler2m 52s
-
(Locked)
Modifying the notification click event3m 48s
-
(Locked)
Creating the web push script6m
-
(Locked)
Testing the hosted app5m 7s
-
(Locked)
-
-