-
-
Notifications
You must be signed in to change notification settings - Fork 90
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
chore: merge from dev #1205
chore: merge from dev #1205
Conversation
WalkthroughWalkthroughThese updates introduce enhancements and adjustments across various components of a project, focusing on improving Vue integration with the Tanstack Query plugin and refining workflow configurations. Key changes include the addition of a new repository to a GitHub workflow, the introduction of a function to streamline query hook input type generation, and significant refactoring to support Vue-specific types and functionalities in the Tanstack Query plugin. Additionally, a minor adjustment in the TRPC plugin improves the handling of schema imports. Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Review Status
Configuration used: CodeRabbit UI
Files ignored due to path filters (3)
packages/plugins/trpc/tests/projects/t3-trpc-v10/src/server/api/routers/generated/routers/Post.router.ts
is excluded by!**/generated/**
packages/plugins/trpc/tests/projects/t3-trpc-v10/src/server/api/routers/generated/routers/User.router.ts
is excluded by!**/generated/**
pnpm-lock.yaml
is excluded by!pnpm-lock.yaml
,!**/*.yaml
Files selected for processing (4)
- .github/workflows/update-samples.yml (1 hunks)
- packages/plugins/tanstack-query/src/generator.ts (5 hunks)
- packages/plugins/tanstack-query/src/runtime/vue.ts (7 hunks)
- packages/plugins/trpc/src/helpers.ts (1 hunks)
Additional Context Used
Additional comments not posted (12)
.github/workflows/update-samples.yml (1)
19-19
: The addition of'zenstackhq/sample-todo-nuxt'
to the list of repositories in the GitHub Actions workflow configuration looks good and follows the existing pattern.packages/plugins/tanstack-query/src/runtime/vue.ts (5)
8-8
: Added imports forQueryKey
,UseInfiniteQueryOptions
,UseMutationOptions
, andUseQueryOptions
are appropriate for the enhancements made to the plugin.
14-14
: The addition ofComputedRef
,MaybeRefOrGetter
, andtoValue
imports fromvue
aligns with the goal of deeper integration with Vue's reactivity system. This is a positive change for Vue developers using the plugin.
65-88
: Refactoring ofuseModelQuery
to use computed options and adjustments in function signatures to acceptMaybeRefOrGetter
orComputedRef
for arguments and options is a significant improvement. It leverages Vue's reactivity system more effectively. Ensure that all calls to this function are updated to match the new signature.
104-121
: The handling ofqueryKey
andpageParam
inuseInfiniteModelQuery
through the use ofMaybeRefOrGetter
orComputedRef
for arguments and options is a thoughtful addition. It enhances the plugin's flexibility and usability within Vue applications.
167-180
: > 📝 NOTEThis review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [147-197]
Utilization of
toValue
for options handling inuseModelMutation
and the adjustments in function signatures to accept Vue-specific types is a commendable improvement. It simplifies the usage of mutation options within Vue applications. However, ensure that the typing problem mentioned in the TODO comment is addressed to avoid potential issues.Would you like me to help address the typing problem mentioned in the TODO comment?
packages/plugins/trpc/src/helpers.ts (1)
240-240
: Modifying the import statement for$Schema
to useimport * as $Schema
is a best practice for handling modules that export multiple members or to address TypeScript module resolution quirks. This change is likely to improve the reliability of schema imports for thetrpc
plugin.packages/plugins/tanstack-query/src/generator.ts (5)
97-97
: The introduction of themakeQueryArgsType
function to refine the logic for generating query hook input types is a positive change. It enhances the flexibility and usability of the plugin within Vue applications by allowing for Vue-specific types.
570-570
: Adding imports forMaybeRefOrGetter
andComputedRef
in themakeBaseImports
function is necessary for the enhancements made to the plugin. This change supports the integration with Vue.js by allowing the plugin to handle Vue-specific types more effectively.
590-597
: ThemakeQueryArgsType
function's implementation to handle Vue-specific types (MaybeRefOrGetter
andComputedRef
) is a thoughtful addition. It ensures that the plugin can leverage Vue's reactivity system more effectively.
617-622
: The adjustments in themakeQueryOptions
function to return Vue-specific types (MaybeRefOrGetter
orComputedRef
) for query options is a significant improvement. It enhances the plugin's integration with Vue.js by allowing for more flexible and reactive query options.
647-650
: The modifications in themakeMutationOptions
function to handle Vue-specific types for mutation options is a commendable improvement. It simplifies the usage of mutation options within Vue applications and aligns with the goal of deeper integration with Vue's reactivity system.
Summary by CodeRabbit