| Index: lib/compiler/implementation/emitter.dart
|
| diff --git a/lib/compiler/implementation/emitter.dart b/lib/compiler/implementation/emitter.dart
|
| index bcda9f670969acc8efc2b149f7091a0e9188dbb8..4fafc8382e2482e7409c417a20dd68482343419d 100644
|
| --- a/lib/compiler/implementation/emitter.dart
|
| +++ b/lib/compiler/implementation/emitter.dart
|
| @@ -988,7 +988,7 @@ $mainEnsureGetter
|
| }
|
| buffer.add("""
|
| if (typeof window != 'undefined' && typeof document != 'undefined' &&
|
| - window.addEventListener && document.readyState != 'complete') {
|
| + window.addEventListener && document.readyState == 'loading') {
|
| window.addEventListener('DOMContentLoaded', function(e) {
|
| ${mainCall};
|
| });
|
|
|