I am using DATATABLE to display the data! Once No data available in table and all data displayed successfully and other time No data available in table doesn’t diplayed to me and the data displayed successfully !
So that makes me a little crazy !
The display when I use console.log("Users : ", Users.find().count()); give me Users : 0 and Users : 9 (the real number of documents) in the same time !
Any help ?
The time that is needed for all data to be loaded depends on your server, your publication, … Try to optimize your publications first.
You can use a neat template helper Template.subscriptionsReady. You should read this. The blog post explains how you can subscribe to the data and wait for it to be loaded.
You basically have 2 options for this. Server Side Rendering, or the fast-render package which will make subscription data available on the client when the page first renders by sending the data down with the initial html of the page.