parse-community / ParseReact

Seamlessly bring Parse data into your React applications.
https://parseplatform.org
Other
1.3k stars 209 forks source link

Observer data is fails! #186

Open jamlfy opened 6 years ago

jamlfy commented 6 years ago

Well

import React from 'react';
import Parse, { Query } from 'parse/react-native';
import { Component } from 'parse-react/react-native';

class Foo extends (Component(React)) {
   constructor(...args) {
     super(...args);
   }
   observer (){
     return { data : (new Query('data'))  }
   }
  render() {
  }
}

When delete or unmount the Component is show this._subscriptions[name].dispose is not a function. And NEVER give the data.

    "parse": "1.10.0",
    "parse-react": "0.5.2",
    "react": "16.0.0-alpha.12",
    "react-native": "0.45.1",

If you want to close the project, however, all of these believe that they have been solved.

bosz commented 4 years ago

Oh Lord, someone help. I've been stuck here for the past 2 months. Any help on how to go past this stage?

@alejonext , did you find any solution? :cryyyyyy

lacker commented 4 years ago

Try sticking a print statement in right before the exception is thrown, and seeing what sort of object this._subscriptions[name] is. Seems like it should be something with a dispose, but it isn't. Then track backwards to see how the wrong sort of object got stuck into this._subscriptions