mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Use the mobile-launch-screen package in todos
The example doesn't "flash" with the white page on mobile when launched.
This commit is contained in:
4
examples/todos/client/launchScreenConf.js
Normal file
4
examples/todos/client/launchScreenConf.js
Normal file
@@ -0,0 +1,4 @@
|
||||
if (Meteor.isCordova) {
|
||||
LaunchScreen.controlManually = true;
|
||||
}
|
||||
|
||||
@@ -31,6 +31,11 @@ Router.map(function() {
|
||||
},
|
||||
data: function() {
|
||||
return Lists.findOne(this.params._id);
|
||||
},
|
||||
action: function () {
|
||||
this.render();
|
||||
if (Meteor.isCordova)
|
||||
LaunchScreen.hide();
|
||||
}
|
||||
});
|
||||
|
||||
@@ -45,4 +50,4 @@ Router.map(function() {
|
||||
if (Meteor.isClient) {
|
||||
Router.onBeforeAction('loading', {except: ['join', 'signin']});
|
||||
Router.onBeforeAction('dataNotFound', {except: ['join', 'signin']});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user