简体   繁体   中英

Can I have a PWA without caching any assets?

I want to use a PWA to allow my small app to be installable, but there is no real need for it to be 'offline ready' - it's a vue app that is constantly calling the server for data and it simply does not work without the network.

If I have a serviceworker that does not bother to cache anything, can I still install it to the device homescreen as per usual, and does it simply request all assets every time it loads up? Are there other limitations here?

I think you can cache your vue.js index.html , and if you want, that will resolve as the answer for the 200 offline problem. As vue.js implements the SPA model, the whole application will be controlled by the JS, even the routes, so just make sure you don't cache your dist js file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM