ParseReact
                                
                                 ParseReact copied to clipboard
                                
                                    ParseReact copied to clipboard
                            
                            
                            
                        Queries aren't cached
I render a component w/ a query, and then I leave that view (component is unmounted), and when I go back to the view the queried data is not available -- it has to be loaded again. I would expect the old data to be loaded immediately, and then replaced when the pending query returns.
I was under the assumption that the objects where being cached in the ObjectStore? But when I look at the javascript console, I am seeing API calls being made
https://github.com/ParsePlatform/ParseReact/blob/dc1d5731e3d16d7c9663db0fa7cc2c52db379993/lib/ObjectStore.js
I'm not sure if this is the issue, but I had a similar problem of query results being discarded and then refetched between components mounting & unmounting, so I dug a little deeper.
I'm subclassing the ES6 ParseComponent class in my React components and in particular the componentWillUpdate function was causing my component to resubscribe to all queries on every view transition (See ParseComponent.js).
function componentWillUpdate(nextProps, nextState) {
    // Only subscribe if props or state changed
    if (nextProps !== this.props || nextState !== this.state) {
      this._subscribe(nextProps, nextState);
    }
}
Here nextProps is a complex object and comparing it to this.props returns false even when they are unchanged, which causes the resubscribe. Commenting out this part I found that all worked fine and the component subscribed and unsubscribed correctly on mount and unmount - and there was no additional resubscribe between view transitions.
Can anyone else confirm that I am on the right track here and seeing things correctly? Is this a bug or am I missing something important?