-
Notifications
You must be signed in to change notification settings - Fork 448
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(codegen): generate SanityQueries interface in @sanity/codegen (#…
…6997) (#7304) * fix(deps): update dependency @sanity/client to ^6.21.1 (#7215) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * feat(typegen): groq/define module with a defineQuery helper * feat(typegen): Recognize queries that are wrapped in defineQuery calls * feat(typegen): Add overloadClientMethods option to @sanity/codegen * refactor(codegen): Return the typename of a generated type node so we can store it for later use * feat(typegen): Add generateTypeMap helper to TypeGenerator * feat(typegen): Allow codegen cli to generate the SanityQueries type map * docs(typegen): Add docs about defineQuery to groq README * refactor(groq): Allow defineQuery to live in the groq package * refactor(groq): Use the correct groq import in codegen tests * fix(codegen): Only use defineQuery when it comes from the groq package * refactor(codegen): Avoid changing the signature for generateTypeNodeTypes * refactor(codegen): Use typeNode to reference types in typeGenerator * feat(codegen): Handle duplicate query strings --------- Co-authored-by: Romeo Van Snick <[email protected]>
- Loading branch information
Showing
17 changed files
with
586 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.