Skip to content

Add allowance query options#10

Merged
gndelia merged 3 commits intomasterfrom
add-allowance-query-options
Mar 18, 2026
Merged

Add allowance query options#10
gndelia merged 3 commits intomasterfrom
add-allowance-query-options

Conversation

@gndelia
Copy link
Contributor

@gndelia gndelia commented Mar 18, 2026

Description

This PR exports allowanceQueryOptions so consumers of the package can use allowance from the query cache outside of hooks. No changes in behaviour

Screenshots

N/A

Checklist

  • Manual testing passed.
  • Automated tests added, or N/A.
  • Documentation updated, or N/A.
  • Environment variables set in CI, or N/A.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR exposes a reusable allowanceQueryOptions helper so consumers can construct React Query options/keys for ERC20 allowance queries and interact with the query cache outside of the useAllowance hook.

Changes:

  • Added allowanceQueryOptions (built via queryOptions) and refactored useAllowance to use it.
  • Adjusted React Query imports/types to support the new options helper.
  • Bumped package version to 1.4.0.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/useAllowance.ts Introduces and exports allowanceQueryOptions, and refactors useAllowance to consume it.
package.json Version bump to publish the new exported API.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@gndelia gndelia merged commit 5f1187a into master Mar 18, 2026
11 checks passed
@gndelia gndelia deleted the add-allowance-query-options branch March 18, 2026 18:25
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

Successfully merging this pull request may close these issues.

4 participants