Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Prevent side effects on bulletTrain.init #16

Closed
askielboe opened this issue Nov 29, 2019 · 2 comments
Closed

Feature request: Prevent side effects on bulletTrain.init #16

askielboe opened this issue Nov 29, 2019 · 2 comments
Assignees

Comments

@askielboe
Copy link

We use this library in a react native app and wrap the onChange callback in an event channel using redux saga. Since we only subscribe to channel updates after initialization it would be great if there was an option to prevent API calls during bulletTrain initialization (as to not waste our paid API calls).

Currently we use a workaround setting disableCache: true as this will stop getFlags from being called on init, but this feels like sort of a hack.

Having an explicit way to call bulletTrain.init without side effects would be great! 🙏🏼

@kyle-ssg kyle-ssg self-assigned this Dec 2, 2019
@kyle-ssg
Copy link
Member

kyle-ssg commented Dec 2, 2019

Ok yep, makes sense, will add this later today.

kyle-ssg added a commit that referenced this issue Dec 7, 2019
@kyle-ssg
Copy link
Member

kyle-ssg commented Dec 7, 2019

Apologies for the delay!

Added preventFetch option to init as of 0.83 of bullet-train-client and react-native-bullet-train

@kyle-ssg kyle-ssg closed this as completed Dec 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants