client app token in firebase console code example

Example 1: getting firebase token

$ firebase token:ci

Example 2: import firebase cloud messaging web

import ReactDOM from "react-dom";import App from "./App";if ("serviceWorker" in navigator) {  navigator.serviceWorker    .register("./firebase-messaging-sw.js")    .then(function(registration) {      console.log("Registration successful, scope is:", registration.scope);    })    .catch(function(err) {      console.log("Service worker registration failed, error:", err);    });}ReactDOM.render(, document.getElementById("root"));