iaphub / react-native-iaphub

The easiest way to implement IAP (In-app purchase) in your React Native app.
https://www.iaphub.com/
MIT License
319 stars 21 forks source link

Update types for `getActiveProducts` and export subscription states #59

Closed andrico1234 closed 3 years ago

andrico1234 commented 3 years ago

Even though getActiveProducts takes options as arguments, as specified in the README, it looks like these options haven't been added to the typings.

Also it would be useful to have the subscription states: active, grace_period, retry_period, and paused exported for type safety reasons.

Massive thanks to you all for making this package, it's a life saver, and so easy to use!

andrico1234 commented 3 years ago

P.S. if you want to add this to the repo i'll behappy to quickly whip up an MR

iaphub commented 3 years ago

Thanks @andrico1234 🙏 You're totally right, I just committed a fix: https://github.com/iaphub/react-native-iaphub/commit/11efbc52a7e264761b190e2c9f40a905837e628c Let me know if it seems correct to you, thanks.

andrico1234 commented 3 years ago

They're perfect! 🙌

iaphub commented 3 years ago

Great 👍 The fix is available in react-native-iaphub@6.1.1