このドキュメントは 以下の2つのドキュメントをよりプリミティブに理解するためのDRYな備忘録です。 Adding Push Notifications to a Web App | Web | Google Developers The Web Push Protocol | Web | Google Developers 背景 かつて サーバからブラウザにプッシュ通知を送りたい(非WebSocket、非ロングポーリング) - DRYな備忘録 これ書いたけど、改めてProgressive Web Appのドキュメント行ったらアホみたいに分かりづらくなってて不条理を感じたので書きます。 サーバからPush通知がブラウザに対して送れて、ブラウザのjsが閉じててもServiceWorkerが生きてるからNotificationが出る、っていうやつです。最近だとウェブのGmailと
![webブラウザにPush通知送るサーバとjsのサンプル - DRYな備忘録](https://cdn-ak-scissors.b.st-hatena.com/image/square/05bb7875a3a9e5caad6cdb194ec2465f15dd1c25/height=288;version=1;width=512/https%3A%2F%2Fcdn-ak.f.st-hatena.com%2Fimages%2Ffotolife%2Fo%2Fotiai10%2F20170619%2F20170619200505.png)