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

feat(types): Make ExtractState public #2935

Merged
merged 4 commits into from
Jan 7, 2025

Conversation

vorant94
Copy link
Contributor

@vorant94 vorant94 commented Jan 5, 2025

Related Bug Reports or Discussions

Fixes #2928

Summary

after asking about how to infer state type outside of state declaration it happens that there is a dedicated but internal only type helper for it called ExtractState

this PR makes this helper public, moves it to vanilla.ts since its not react-specific and adds a short docs paragraph with its usage example

Check List

  • pnpm run prettier for formatting code and docs

Copy link

vercel bot commented Jan 5, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
zustand-demo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 7, 2025 4:06pm

Copy link

codesandbox-ci bot commented Jan 5, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Copy link

pkg-pr-new bot commented Jan 5, 2025

Open in Stackblitzdemostarter

npm i https://pkg.pr.new/zustand@2935

commit: 09e59a8

Copy link
Member

@dai-shi dai-shi left a comment

Choose a reason for hiding this comment

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

Perfect!

@dai-shi dai-shi added this to the v5.0.3 milestone Jan 5, 2025
@dai-shi dai-shi changed the title Make ExtractState public feat(types): Make ExtractState public Jan 5, 2025
@dai-shi dai-shi merged commit d2ac820 into pmndrs:main Jan 7, 2025
26 checks passed
@vorant94 vorant94 deleted the feature/extract-state branch January 8, 2025 06:06
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.

2 participants