Skip to content

Commit 3ff6e27

Browse files
authored
feat: add flutter first frame listener (#10)
1 parent cf83222 commit 3ff6e27

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

__brick__/web/index.html

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,11 @@
137137
},
138138
onEntrypointLoaded: function(engineInitializer) {
139139
engineInitializer.initializeEngine().then(async function(appRunner) {
140-
progressBar.remove();
141-
document.body.classList.remove('loading-mode');
140+
window.addEventListener("flutter-first-frame", function () {
141+
progressBar.remove();
142+
document.body.classList.remove('loading-mode');
143+
});
144+
142145
appRunner.runApp();
143146
});
144147
}

0 commit comments

Comments
 (0)