在移动设备中浏览 PWA

Adi*_*iti 4 javascript mobile android progressive-web-apps

所以我今天正在探索 PWA,并关注了Your First Progressive Web App。它需要 5 分钟并在我的笔记本电脑上工作,但问题是,我不知道如何通过我的手机浏览它。所以我搜索并找到了如何从我的 Android 设备访问我的本地主机?但不幸的是,那里提供的答案对我不起作用。

为什么会这样?PWA 是否需要某种不同的设置?我在这件事上做错了吗?另外,我找不到任何可以带您在移动设备中实际浏览 PWA 的教程。为什么?

Ank*_*rav 6

While the Your First Progressive Web App tutorial tells you to start a server in your localhost. So as mentioned by @Anand, you won't be able to simply access the PWA in your phone.

The most simple solution is to use ngrok. Using it will expose a public URL for your web app which you can access in any device you want.

只需从这里安装 ngrok并完成。干杯;)