Browse Source

fix(mobile): hide splash as early as possible

Fix #9794
Andelf 2 years ago
parent
commit
27035b471c
1 changed files with 2 additions and 3 deletions
  1. 2 3
      src/main/frontend/handler.cljs

+ 2 - 3
src/main/frontend/handler.cljs

@@ -221,11 +221,10 @@
      (mobile/mobile-preinit))
    (-> (p/let [repos (get-repos)
                _ (state/set-repos! repos)
+               _ (mobile-util/hide-splash) ;; hide splash as early as ui is stable
                _ (restore-and-setup! repos)]
          (when (mobile-util/native-platform?)
-           (p/do!
-            (mobile-util/hide-splash)
-            (state/restore-mobile-theme!))))
+           (state/restore-mobile-theme!)))
        (p/catch (fn [e]
                   (js/console.error "Error while restoring repos: " e)))
        (p/finally (fn []