The code generated by graphql codegen provides inconsistent letter casing. I am almost certain that something is not right in the config, or some other mistake i made. I would appreciate guidance the proper setup to fix this issue, everything else seems to work.
Only 3 constraints break in the code the 3 tables in the database, but that is enough for it not to work.
The generated code:
/** on_conflict condition type for table "Batch" */
export type Batch_On_Conflict = {
constraint: Batch_constraint;
update_columns?: Array<Batch_update_column>;
where?: InputMaybe<Batch_Bool_Exp>;
};
/** unique or primary key constraints on table "Batch" */
export type Batch_Constraint =
/** unique or primary key constraint on columns "id" */
| 'Batch_pkey';
The config:
overwrite: true
ignoreNoDocuments: true
schema:
- http://localhost:8080/v1/graphql:
headers:
'x-hasura-admin-secret':
documents:
- "./src/**/*.graphql"
generates:
./out/sdk/batchSDK.ts:
plugins: [
'typescript',
'typescript-operations',
'typescript-react-apollo',
]
config:
preResolveTypes: true
skipTypename: false
withHooks: true
withHOC: false
withComponent: false
enumsAsTypes: true
constEnums: true
decapitalizeFields: true
namingConvention: 'change-case-all#pascalCase'
useSemanticNaming: true,
transformUnderscore: true
reactApolloVersion: 3
./graphql.schema.json:
plugins:
- "introspection"
Please note that this config is the latest iteration, the letter casing seems to change the case properly, but neither preset fixes this particular issue pasted above.
Any thoughts?