wdio-intercept-service
wdio-intercept-service copied to clipboard
Proposal: Use performance API to initialize the data of the interceptor.
Hi, this might be out of the scope of this project in all honesty, however, I think it might help this plugin to be even more ubiquitous for network capture in the WebdriverIO ecosystem.
The basic principle is quite simple: When the user setup the interceptor, using the Performance API, get all the events related to the network. From what I can see here, the following entry types should suffice:
- frame
- navigation
- resource
This would however certainly qualified as a breaking change. Therefore, if that's not the default behaviour that the plugin wants to use moving forward, this feature should be behind an option on the setupInterceptor function. However, I do think that it's a better default behaviour than the current one, but an option could still be exposed to allow users to upgrade to the next major update to disable this new behaviour, allowing a more frictionless update.