【问题标题】:Is there a way to create a native thread for PWAs (Progressive Web Apps)? I need to access Geolocation when the browser has closed有没有办法为 PWA(渐进式 Web 应用程序)创建本机线程?浏览器关闭后我需要访问地理位置
【发布时间】:2017-10-16 16:17:12
【问题描述】:

我有一个 Progressive Web App,它需要不断更新用户的位置。

Service Worker 不够用,因为他们无法访问 navigation.geolocation 对象,而且我当前使用 React 组件的解决方案在关闭浏览器时停止。

我尝试过 React Native Workers (https://github.com/devfd/react-native-workers),但无法使用 create-react-app 安装。

对想法持开放态度。

【问题讨论】:

    标签: reactjs react-native geolocation progressive-web-apps


    【解决方案1】:

    不,如果您想要一个长时间运行的后台进程,您将必须创建一个本机应用程序。

    【讨论】:

      猜你喜欢
      • 2018-10-27
      • 1970-01-01
      • 1970-01-01
      • 2020-08-05
      • 2018-01-04
      • 2018-12-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多