5

我正在 Rails 5 中创建新应用程序。我想使用 Web 推送通知。我没有找到任何可以在网络推送通知中帮助我的文档。

任何帮助都将是可观的。在此先感谢。

4

2 回答 2

9

我正在使用这个:https ://github.com/zaru/webpush

很好的文档,很好的例子!

于 2018-02-07T21:32:21.897 回答
1

这是一篇非常好的博客文章,对我很有帮助- https://rossta.net/blog/using-the-web-push-api-with-vapid.html

好消息是 Github 上有示例代码,您可以使用它 - https://github.com/rossta/serviceworker-rails-sandbox

除此之外,如果您不熟悉使用网络推送通知,只需阅读 Google 的网络基础教程也不是一个坏主意。

https://developers.google.com/web/fundamentals/codelabs/push-notifications/

于 2018-04-03T13:41:44.563 回答