react-packages
react-packages copied to clipboard
react-meteor-data: handle.ready() is always false
According to the docs, this should work:
const listLoading = useTracker(() => {
// Note that this subscription will get cleaned up
// when your component is unmounted or deps change.
const handle = Meteor.subscribe('todoList', listId);
return !handle.ready();
}, [listId]);
However, if I try it out, the returned value is always true, i.e. ready() is always false.
Note: I am using publishComposite in the background.
- Does it work outside of
useTracker? Like, in a standardTracker.autorun? - Does it work without the deps array (i.e., without the second
useTrackerargument)?
2. Does it work without the deps array (i.e., without the second
useTrackerargument)?
This did not change anything. I have yet to try out 1.