PostHog / posthog-js-lite

Reimplementation of posthog-js to be as light and modular as possible.
https://posthog.com/docs/libraries
MIT License
70 stars 36 forks source link

React native feature flag payload #97

Closed filipef101 closed 1 year ago

filipef101 commented 1 year ago

Describe the solution you'd like

Support for feature flags payloads.

If the core supports it, seems it could be a simple and easy addition to react-native library

Describe alternatives you've considered

Related sub-libraries

Additional context

Thank you for your feature request – we love each and every one!

neilkakkar commented 1 year ago

Hey @filipef101 , have you tried posthog.getFeatureFlagPayload() in react native? iirc, this should already be supported, precisely because the core supports it.

filipef101 commented 1 year ago

Hey @filipef101 , have you tried posthog.getFeatureFlagPayload() in react native? iirc, this should already be supported, precisely because the core supports it.

Pretty sure it's not exposed to the rn package. The docs also say its not available on the rn package

neilkakkar commented 1 year ago

I'll update the docs, tried it internally and it works. Would you mind trying & ensuring you're on the latest version?

neilkakkar commented 1 year ago

Also, mind sharing link to docs where you saw this? Just ensuring I'm not missing a few places to update

filipef101 commented 1 year ago

On the web dashboard, and regular docs that don't include/show the get payload option.

Hopefully just some plumbing needed to get this working 😌

image
filipef101 commented 1 year ago

@neilkakkar Updated to latest and see it now, thanks! Assumed it was not present given the above

neilkakkar commented 1 year ago

Perfect, thanks, will update those places 👀