-
Notifications
You must be signed in to change notification settings - Fork 52
Commit bbc2cb6
committed
Add Network module
This is designed to support logging network requests. Important use
cases include:
* Determing if a specific network request occured
* Monitoring request performance
* Generating a HAR file for offline analysis of requests
This does not currently attempt to support network request
interception (i.e. mutable access to requests), but the intent is that
the same lifecycle events could be used in a blocking way.
It also currently only supports HTTP-type requests and not
e.g. WebSockets. Some support for integration with service workers is
also missing.
The typical order of events is
network.beforeRequestSent - before request is sent, would later be the
right point to change the request headers or body or prevent the
request entirely.
network.responseStarted - after response headers are received, but
before body. Would later be a point to override the response headers
or body.
network.responseCompleted - after the request is fully complete.
network.fetchError - After any error that will prevent the request
from completing.
Compared to CDP this is missing an event for data being
received. Compared to WebExtensions, this is missing an event after
the headers are sent but before the data is sent.1 parent 71abe1b commit bbc2cb6Copy full SHA for bbc2cb6
1 file changed
+845
-9
lines changed
0 commit comments