react-native-meteor
Advanced tools
Comparing version 1.0.0-beta17 to 1.0.0-beta18
{ | ||
"name": "react-native-meteor", | ||
"version": "1.0.0-beta17", | ||
"version": "1.0.0-beta18", | ||
"description": "DDP React-native Client", | ||
@@ -5,0 +5,0 @@ "main": "src/Meteor.js", |
@@ -15,3 +15,3 @@ [](https://badge.fury.io/gh/inProgress-team%2Freact-native-meteor) | ||
Meteor-like methods for React Native. **Currently in v1.0.0-beta17** ! For old docs, see [v0.6.2 documentation](https://github.com/inProgress-team/react-native-meteor/tree/0.6.2) (classic ddp interface). | ||
Meteor-like methods for React Native. **Currently in v1.0.0-beta18** ! For old docs, see [v0.6.2 documentation](https://github.com/inProgress-team/react-native-meteor/tree/0.6.2) (classic ddp interface). | ||
@@ -178,7 +178,7 @@ ## What is it for ? | ||
- [X] [Helper for Meteor-CollectionFS](https://github.com/inProgress-team/react-native-meteor/issues/18) | ||
- [ ] [Accounts Methods 0/4](https://github.com/inProgress-team/react-native-meteor/issues/30) | ||
- [ ] [Meteor user methods 0/2](https://github.com/inProgress-team/react-native-meteor/issues/31) | ||
- [ ] [Update and upsert methods 0/2](https://github.com/inProgress-team/react-native-meteor/issues/24) | ||
- [ ] [Accounts Methods 2/4](https://github.com/inProgress-team/react-native-meteor/issues/30) | ||
- [ ] [Meteor user methods 1/2](https://github.com/inProgress-team/react-native-meteor/issues/31) | ||
- [X] [Update method](https://github.com/inProgress-team/react-native-meteor/issues/24) | ||
- [X] [When disconnected, minimongo insert is pushing data to view but not send to server when reconnecting.](https://github.com/inProgress-team/react-native-meteor/issues/29) | ||
Pull Requests are welcome ! :) |
@@ -8,14 +8,17 @@ import Trackr from 'trackr'; | ||
if(this.getMeteorData) { | ||
this.data = {}; | ||
this._meteorDataManager = new MeteorDataManager(this); | ||
const newData = this._meteorDataManager.calculateData(); | ||
this._meteorDataManager.updateData(newData); | ||
} | ||
Data.waitDdpReady(()=>{ | ||
if(this.getMeteorData) { | ||
this.data = {}; | ||
this._meteorDataManager = new MeteorDataManager(this); | ||
const newData = this._meteorDataManager.calculateData(); | ||
this._meteorDataManager.updateData(newData); | ||
} | ||
if(this.startMeteorSubscriptions) { | ||
this._meteorSubscriptionsManager = new MeteorSubscriptionsManager(this); | ||
this._meteorSubscriptionsManager.getMeteorSubscriptions(); | ||
} | ||
if(this.startMeteorSubscriptions) { | ||
this._meteorSubscriptionsManager = new MeteorSubscriptionsManager(this); | ||
this._meteorSubscriptionsManager.getMeteorSubscriptions(); | ||
} | ||
}); | ||
}, | ||
@@ -22,0 +25,0 @@ componentWillUpdate(nextProps, nextState) { |
@@ -17,2 +17,12 @@ import minimongo from 'minimongo-cache'; | ||
waitDdpReady(cb) { | ||
if(this.ddp) { | ||
cb(); | ||
} else { | ||
setTimeout(()=>{ | ||
this.waitDdpReady(cb); | ||
}, 10); | ||
} | ||
}, | ||
_cbs: [], | ||
@@ -19,0 +29,0 @@ onChange(cb) { |
42832
1006