Can Service Workers respond to synchronous XHR requests?

后端 未结 3 1851
[愿得一人]
[愿得一人] 2021-01-03 23:42

I would like to use Service Workers to enhance an existing web site. In particular, I would like to add better offline support by having Service Workers respond to requests

3条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-04 00:22

    According to XMLHttpRequest spec, the fetch procedure for both synchronous and asynchronous requests is the same so, in theory, it should be intercepted but Synchronous XHR has been deprecated so I would not expect Chrome to fix this.

提交回复
热议问题