title: The provided web push applicationServerKey is not valid
body: <p>I am trying to subscribe to web push via the function below.</p>
  
  <pre><code>function postSubscriptionBo() {
    return navigator.serviceWorker.register('/service-worker.js')
    .then(function(registration) {
      const subscribeOptions = {
        userVisibleOnly: true,
        applicationServerKey: APPLICATION_SERVER_KEY
      };
  
      return registration.pushManager.subscribe(subscribeOptions);
    })
    .then(function(pushSubscription) {
      console.log('Received PushSubscription: ', JSON.stringify(pushSubscription));
      return pushSubscription;
    });
  }
  </code></pre>
  
  <p>These are the current steps: <br>
   1. Get the <strong>application server key</strong> from Firebase console > cloud messaging tab > <strong>server key</strong> <br>
   2. Encoded application server key with <strong>window.btoa(server key)</strong> <br>
   3. Removed tailing = from the server key<br>
   4. Browser throws exception: The provided web push applicationServerKey is not valid.</p>
  
  <p>Suggestions on what I am doing wrong here?
  Thanks.</p>