-
-
Notifications
You must be signed in to change notification settings - Fork 136
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question: Why I'm only getting a white screen while the app is starting up? #332
Comments
Is this for Android or iOS? Or both? |
From @gaurav-chandra on January 12, 2016 12:50 I develop for Android so I have checked it for Android only. |
Indeed, NativeScript apps could have slow startup. It could be because of the runtime or the app itself. Can you tell us the startup time reported from
You can find the startup time via the
Also, can you tell us what device/emulator you use? For splash screen, you can read Splash Screen For Your Android Applications article as well. |
This comment was marked as abuse.
This comment was marked as abuse.
@slavchev the time is
@NathanaelA I don't have any major code or cpu intensive task. I just have
setTimeout also does not help in my case. Does require() also take time to initialize? Probably if there are no modules to require, I can speed it up. |
This comment was marked as abuse.
This comment was marked as abuse.
@NathanaelA it is for this app. I wanted to try on the actual app I am building. Yes, there are couple of requires on top of the page. I don't use an emulator. I directly run on device. Lenovo A6000 with Android 5. I will try by removing and calling requires only when needed. |
In the new app here is the log:
|
I can confirm that |
Just to add some more info here:
Additionally, we are constantly working on improving the loading time of the {N} modules - for example for the 1.5.1 release we improved the require routine - modules are loaded only when/if needed: The custom startup snapshots feature mentioned by @slavchev also looks promising - we have a POC and it shows nearly 1s ! improvement. Our target is to reduce the loading time up to a maximum of 1.5 seconds for a first (cold) start. |
This comment was marked as abuse.
This comment was marked as abuse.
@NathanaelA Any research on the matter is more than welcome! Performance, especially the loading time is always with high priority. |
Is this being looked into actively by core nativescript developers? Hello world NS app is still way slower than Hello world Native Java Android app. |
This comment was marked as abuse.
This comment was marked as abuse.
hey @NathanaelA thanks for the clarification. I guess you are right, I can show the splash screen. |
Good news :) Recently @atanasovg merged PR #341. You will hear more details soon. |
snapshot will optimize loading time: |
Very Disappointing for some trying to decide if NativeScript is the one to learn. Great features BUT a let-down. Im really excited until i came across this app size prob. |
@alvirtuoso I wouldn't worry too much about this because it's under development. While the size is larger than we want right now, the pending solutions will address this in short order. |
I wonder if a few of dependencies in the file be in separate thread or web service. I'm no expert but just a thought. |
Loading time is further boosted, because of the static binding generator that now runs by default. |
awesome. will give it a try. |
This is implemented, the app ships with splash by default. More information here: https://github.com/NativeScript/docs/blob/master/publishing/creating-launch-screens-android.md |
From @gaurav-chandra on January 12, 2016 10:11
Why I'm only getting a white screen while the app is starting up? When I click on launcher icon, I get a white screen for sometime and then my application shows.
Copied from original issue: NativeScript/NativeScript#1356
The text was updated successfully, but these errors were encountered: