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

Support prevState typing #39

Merged
merged 1 commit into from
Feb 19, 2025
Merged

Support prevState typing #39

merged 1 commit into from
Feb 19, 2025

Conversation

chungweileong94
Copy link
Owner

Previously, the prevState from formAction will always infer as any, due to type infer limitation.
Now it's possible to type the prevState by defining the second generic type of formAction. It's not ideal, but at least there is an option now.

Copy link

stackblitz bot commented Feb 19, 2025

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

Copy link

changeset-bot bot commented Feb 19, 2025

🦋 Changeset detected

Latest commit: 764a047

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
server-act Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@chungweileong94 chungweileong94 merged commit ca7131a into main Feb 19, 2025
3 checks passed
@chungweileong94 chungweileong94 deleted the prev-state-type branch February 19, 2025 13:58
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.

1 participant