SSR subscription in composeWithTracker
See original GitHub issueHi, I have a problem with flow-router-ssr and the composer function of react-komposer. In the composer function is a subscription of a collection.
function composer(props, onData) {
const handle = Meteor.subscribe('collection');
if (handle.ready()) {
const collection = Collection.find().fetch();
onData(null, {collection});
}
};
export default composeWithTracker(composer)(SomePage);
This is working fine and the SSR renders the page correctly. But when the code is executed I get a “Loading…” indicator for a moment (fast-render). The problem is, that the subscription handle is not ready when it is executed for the first time.
What can I do? Is it possible to deactivate fast-render here and wait for the handle? Thank you
Issue Analytics
- State:
- Created 7 years ago
- Comments:18
Top Results From Across the Web
Do we need to clean up the data for Meteor subscription? #5
In the server, FlowRouter SSR knows how to deal with cleanups. ... unmounted composeWithTracker call .stop() method for each subscription I ...
Read more >Subscription options - SSR Health
Series subscribers receive all publications in that series on the first date publications are made available to any SSR Health client, and also...
Read more >react-komposer-native - npm
react-komposer. Let's compose React containers and feed data into components. TOC. Why; Installation; Basic Usage; API; Using with XXX.
Read more >SSRS Subscriptions (What goes on "under the hood")
To help assist with this I put together the flow chart below that shows the process a subscription goes through, whether it's a...
Read more >ssrcli - PyPI
Then add your SSR configuration using ssrcli and use it. For example, if you have a SSR subscription url, do: # Add a...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
No I haven’t upgraded, waiting for this to be fixed first.
@SachaG are you thinking of upgrading to a newer version of update ? Just double checking with you if you have upgraded or not. If you have not I’ll bite the bullet and try to upgrade 😃