You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Summary
- remove `currentPurchase` / `currentPurchaseError` from `useIAP` in
favor of `onPurchaseSuccess` and `onPurchaseError`
- refresh tests, mocks, and docs to align with the leaner hook API
## Testing
- yarn test src/__tests__/hooks/useIAP.test.ts --watchAll=false
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
- New Features
- Added optional onPurchaseSuccess callback in useIAP to receive
purchase details on successful transactions.
- Breaking Changes
- Removed currentPurchase and currentPurchaseError from useIAP, along
with their clear functions. Migrate to the onPurchaseSuccess callback
for purchase handling.
- Test/mocking surface adjusted accordingly.
- Documentation
- Updated commit message guidelines to follow the Angular Conventional
Commits format.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
4
4
5
5
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
7
+
## [Unreleased]
8
+
9
+
### Breaking
10
+
11
+
- JS: `useIAP` no longer returns `currentPurchase`, `currentPurchaseError`, or the associated clear helpers; consumers should rely on the `onPurchaseSuccess` / `onPurchaseError` callbacks moving forward.
0 commit comments