fix(trace-viewer): allow Chrome extension fallback in SW (#29954)

https://github.com/microsoft/playwright/issues/29144
This commit is contained in:
Max Schmitt 2024-03-15 16:27:07 +01:00 committed by GitHub
parent 5bc6ca6345
commit be465c6a1c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -68,6 +68,10 @@ async function loadTrace(traceUrl: string, traceFileName: string | null, clientI
// @ts-ignore
async function doFetch(event: FetchEvent): Promise<Response> {
// In order to make Accessibility Insights for Web work.
if (event.request.url.startsWith('chrome-extension://'))
return fetch(event.request);
const request = event.request;
const client = await self.clients.get(event.clientId);