-
-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FormData date type casted with qutoes #622
Comments
Hey, can you share your config, which version you're on, and OpenAPI spec? |
Version should be import { defineConfig } from '@hey-api/openapi-ts';
export default defineConfig({
client: 'fetch',
input: '../dashboard/api.json',
output: {
format: false,
lint: false,
path: 'src/client',
},
types: {
enums: 'typescript',
},
}); |
I assume the same happens with the latest version? Can you share your OpenAPI spec? |
Yes it does happen on
Generates: export type StoreRequestData = {
acceptLanguage?: string;
formData?: {
[key: string]: ();
};
service: string;
}; I'd expect it to be export type StoreRequestData = {
acceptLanguage?: string;
formData?: {
[key: string]: unknown;
};
service: string;
}; |
Great, thanks! And what does your payload passed to form data look like? |
It's a simple structure, there's no depth, some values are |
Going to close this issue as it's no longer active. If anyone else sees this, please try migrating away from legacy clients as they're in maintenance mode. |
Description
After running the code below with a
new Date()
the code gets parsed as the snippet below the code, I'd expect it to return2024-05-22T23:00:00.000Z
as opposed to"2024-05-22T23:00:00.000Z"
OpenAPI specification (optional)
No response
Configuration
No response
System information (optional)
OS: EndeavourOS rolling x86_64
Browser: Firefox, Opera, Chromium
Bun version: 1.1.8
The text was updated successfully, but these errors were encountered: