[web] Fix JS crash when FF blocks service workers. (#106072)

This commit is contained in:
David Iglesias
2022-06-16 19:22:07 -07:00
committed by GitHub
parent 2c15e3cae4
commit b1b1ee9ca6
5 changed files with 160 additions and 3 deletions

View File

@@ -0,0 +1,10 @@
// Copyright 2014 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'dart:html' as html;
Future<void> main() async {
const String response = 'CLOSE?version=1';
await html.HttpRequest.getString(response);
html.document.body?.appendHtml(response);
}