Why do FlowRouter apps start so slowly on Android/Cordova?


#1

The android/cordova Meteor client for this standard example:


takes over 5 seconds to load on an android device.
Note that in this example there is almost no data to transfer between server-client, not loads of content or other big sources of data.
I am not seeing this slowness on iOS devices.

I have been through all the related searches here and StackOverflow related to slow Android/Meteor/Cordova (e.g., those speculating about launch-screen slowness etc). None of that works for me, but more importantly, non-flow router apps like iron-router examples or the ‘meteor create --example clock’, run fast on android with or without launch-screen and those other ‘fixes’

Can anyone confirm, deny, or better yet know what is going on with this issue with flow-router apps?
Cheers.

PS
I had to tweak example.html and example.js to get the subscriptions to work properly.
example.html diff:

<template name="post">
    {{#if post}}
      <div>Post: {{post.title}}</div>
    {{else}}
      <div>Home</div>
    {{/if}}
 </template>

example.js diff:

function createPostsSubscription(templateInstance) {
  templateInstance.postsSubHandle = templateInstance.subscribe('posts', FlowRouter.getParam('slug'),
      {
        onReady: function () {
          console.log("Posts subscription on post page is ready. There are "
              + Posts.find().fetch().length + " posts.");
        },
        onStop: function () {
          console.log("Posts subscription on post page has been stopped.");
        }
      }
  );
}


if (Meteor.isClient) {
  Template.post.onCreated(function() {
    createPostsSubscription(this);
    var self = this;
    self.autorun(function() {
      self.subscribe('post', FlowRouter.getParam('slug'));
    });
  });

  Template.post.helpers({
    post: function() {
      return Posts.findOne({ slug: FlowRouter.getParam('slug') });
    }
  });
}

#2

I notice the same. Have you find a true workaround?