This repository was archived by the owner on May 13, 2026. It is now read-only.
refactor(constants): drop 2 dead SchemaState type aliases - #1016
Merged
Conversation
Both aliases are zero-consumer — verified by `git grep` against origin/main 9f65e5b. The canonical `SchemaState` type lives in `src/types/schema.ts:38`, which is what `schemaClient.ts:7` imports. The two deleted aliases were duplicate re-derivations nobody imported from `constants/*`. - constants/api.ts:152-153 — banner comment + dead alias (the `SCHEMA_STATES` value re-export on lines 134-136 stays live). - constants/schemas.ts:14 — dead alias (the `SCHEMA_STATES` value and `RANGE_SCHEMA_CONFIG` stay live). Follow-up to the constants/ cleanup pattern in #1014 and #1015. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
shiba4life
enabled auto-merge
May 12, 2026 07:07
This was referenced May 12, 2026
github-merge-queue Bot
pushed a commit
that referenced
this pull request
May 12, 2026
SchemaCacheMeta and DefaultSchemaState are used only inside redux.ts (as the type of the `cache` field and the annotation on DEFAULT_SCHEMA_STATE, respectively); the constants barrel doesn't re-export them. Continues the dead-export audit pattern from PRs #1014, #1015, #1016, #1017, and #1018. Interfaces are preserved as file-local typing. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Pure-deletion of two zero-consumer
SchemaStatetype aliases inconstants/. Continues the dead-export audit from #1014 and #1015.Both aliases are dead — verified at base
9f65e5b:The canonical
SchemaStatetype lives insrc/types/schema.ts:38, which is whatsrc/api/clients/schemaClient.ts:7imports.Changes
src/server/static-react/src/constants/api.ts(was lines 152–153) — banner comment + deadexport type SchemaState = (typeof SCHEMA_STATES)[keyof typeof SCHEMA_STATES];. TheSCHEMA_STATESvalue re-export on lines 134–136 stays untouched (consumed bymutationClient.ts,schemaClient.ts,api/index.ts).src/server/static-react/src/constants/schemas.ts(was line 14) — dead alias of the same shape. TheSCHEMA_STATESconst andRANGE_SCHEMA_CONFIGstay untouched.Net: 2 files, 6 deletions, 0 additions.
Verify
npm run typecheck✅npm test✅ (788 / 788)npm run lint— 1 pre-existing error inQueryForm.tsx, not introduced hereTest plan
git grep -nE "^export type SchemaState =" -- src/server/static-react/src/constants/returns 0 hitsSCHEMA_STATES/RANGE_SCHEMA_CONFIGstill live (grep + typecheck)