fullstackreact / react-native-firestack

A firestack v3 react-native implementation
MIT License
715 stars 132 forks source link

Trying to us Remote Config gives a stack overflow error. #317

Open ryanwalker opened 7 years ago

ryanwalker commented 7 years ago

I cannot find any examples of how to use remote config. I looked at the code and attempted the following:

import Firestack from 'react-native-firestack'
this.firestack = new Firestack();
console.log(firestack.remoteConfig.setDev());

I get an infinite loop that blows the stack. Looking in the code I see why. In firestack.js

  get remoteConfig() {
    if (!this.remoteConfig) {
      this.remoteConfig = new RemoteConfig(this._remoteConfig);
    }
    return this.remoteConfig;
  }

This will continue calling itself over and over again. Does remote config even work? What am I missing?