fork of hey-api/openapi-ts because I need some additional things

Merge pull request #899 from hey-api/fix/fetch-date-preserve-name

fix: preserve key name in Date transformation

authored by

Lubos and committed by
GitHub
2ee2463a a2d26ef2

+9 -3
+6
.changeset/proud-wombats-occur.md
··· 1 + --- 2 + '@example/openapi-ts-fetch': patch 3 + '@hey-api/client-fetch': patch 4 + --- 5 + 6 + fix: preserve key name in Date transformation
+1 -1
packages/client-fetch/src/utils.ts
··· 153 153 value: Record<string, unknown> | Date; 154 154 }) => { 155 155 if (value instanceof Date) { 156 - return value.toISOString(); 156 + return `${name}=${value.toISOString()}`; 157 157 } 158 158 159 159 if (style !== 'deepObject' && !explode) {
+1 -1
packages/openapi-ts/test/__snapshots__/test/generated/v3-hey-api-client-fetch-bundle/core/utils.ts.snap
··· 153 153 value: Record<string, unknown> | Date; 154 154 }) => { 155 155 if (value instanceof Date) { 156 - return value.toISOString(); 156 + return `${name}=${value.toISOString()}`; 157 157 } 158 158 159 159 if (style !== 'deepObject' && !explode) {
+1 -1
packages/openapi-ts/test/__snapshots__/test/generated/v3-hey-api-client-fetch-bundle_transform/core/utils.ts.snap
··· 153 153 value: Record<string, unknown> | Date; 154 154 }) => { 155 155 if (value instanceof Date) { 156 - return value.toISOString(); 156 + return `${name}=${value.toISOString()}`; 157 157 } 158 158 159 159 if (style !== 'deepObject' && !explode) {