resultingClientId 只读特性在 FetchEvent interface is the id client that replaces the previous client during a page navigation.

For example, when navigating from page A to page B resultingClientId is the ID of the client associated with page B.

If the fetch request is a subresource request or the request's destination is report , resultingClientId will be an empty string.

句法

var myResultingClientId = fetchEvent.resultingClientId;
					

A DOMString .

范例

self.addEventListener('fetch', function(event) {
  console.log(event.resultingClientId);
});
					

规范

规范 状态 注释
服务工作者
The definition of 'resultingClientId' in that specification.
工作草案 初始定义。

浏览器兼容性

The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request. 更新 GitHub 上的兼容性数据
桌面 移动
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
resultingClientId Chrome 72 Edge 18 Firefox 65 IE 不支持 No Opera 60 Safari 不支持 No WebView Android 72 Chrome Android 72 Firefox Android 65 Opera Android 50 Safari iOS 不支持 No Samsung Internet Android 11.0

图例

完整支持

完整支持

不支持

不支持

另请参阅

元数据

  • 最后修改: