playwright/tests/assets/serviceworkers/fetch/sw.html

6 lines
243 B
HTML

<link rel="stylesheet" href="./style.css">
<script>
window.registrationPromise = navigator.serviceWorker.register('sw.js');
window.activationPromise = new Promise(resolve => navigator.serviceWorker.oncontrollerchange = resolve);
</script>