electron/spec-main/fixtures/extensions/chrome-webRequest-wss/background.js

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
297 B
JavaScript
Raw Normal View History

/* global chrome */
chrome.webRequest.onBeforeSendHeaders.addListener(
(details) => {
if (details.requestHeaders) {
details.requestHeaders.foo = 'bar';
}
return { cancel: false, requestHeaders: details.requestHeaders };
},
{ urls: ['*://127.0.0.1:*'] },
['blocking']
);