Skip to content

Conversation

@sgulseth
Copy link
Member

@sgulseth sgulseth commented Nov 28, 2025

Description

Detect casing and return the generated type name with the same casing. If we can't detect it we fall back to camelCase

What to review

Testing

yes

Notes for release

TypeGen(Breaking!): Return generated type names in same case as the query name case.

@vercel
Copy link

vercel bot commented Nov 28, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
page-building-studio Ready Ready Preview Comment Dec 3, 2025 2:23pm
test-studio Ready Ready Preview Comment Dec 3, 2025 2:23pm
3 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
e2e-studio Ignored Ignored Dec 3, 2025 2:23pm
studio-workshop Ignored Ignored Preview Dec 3, 2025 2:23pm
test-next-studio Ignored Ignored Dec 3, 2025 2:23pm

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

🧪 E2E Preview environment

🔑 Environment Variables for Local Testing

This is the preview URL for the E2E tests: https://e2e-studio-jnjwk9ehg.sanity.dev

To run the E2E tests locally, you can use the following environment variables, then run pnpm test:e2e --ui to open the Playwright test runner.

💬 Remember to build the project first with pnpm build:e2e.

  SANITY_E2E_PROJECT_ID=ittbm412
  SANITY_E2E_BASE_URL=https://e2e-studio-jnjwk9ehg.sanity.dev
  SANITY_E2E_DATASET="update depending the project you want to test (pr-11330-chromium-19896990428 || pr-11330-firefox-19896990428 )"
  SANITY_E2E_DATASET_CHROMIUM=pr-11330-chromium-19896990428
  SANITY_E2E_DATASET_FIREFOX=pr-11330-firefox-19896990428

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

📊 Playwright Test Report

Waiting for E2E tests to finish…

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

⚡️ Editor Performance Report

Deploying studio and running performance tests…

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 44.39% 64014 / 144202
🔵 Statements 44.39% 64014 / 144202
🔵 Functions 48.2% 3410 / 7074
🔵 Branches 79.32% 13005 / 16394
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
packages/@sanity/codegen/src/casing.ts 100% 100% 100% 100%
packages/@sanity/codegen/src/_exports/index.ts 0% 0% 0% 0% 1-9
Generated in workflow #47010 for commit 2442700 by the Vitest Coverage Report Action

Copy link
Contributor

@kbrabrand kbrabrand left a comment

Choose a reason for hiding this comment

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

Nice. Added a suggestion on handling camel case before snake case, but other than that it looks 👍

@sgulseth sgulseth force-pushed the feat/cldx-4359/detect-type-casing branch from 3452935 to 8ad49d5 Compare December 3, 2025 14:17
@bjoerge bjoerge changed the title feat(typegen): return same case when generating types feat(typegen)!: return same case when generating types Dec 3, 2025
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.

3 participants