Description
The new type-only package @hey-api/spec-types is not compatible with any client that use moduleResolution: "nodenext" in their tsconfig.json.
Minimal Reproduce Example
Create a TypeScript project with the following tsconfig.json:
{
"compilerOptions": {
"strict": true,
"module": "nodenext",
"moduleResolution": "nodenext",
}
}
After installing the latest @hey-api/openapi-ts, the type of description is unresolvable and fallback to any.
import type { IR } from "@hey-api/openapi-ts";
export function myFunc(schema: IR.SchemaObject) {
const description = schema.description;
return description;
}
Is it possible to make it compatible with moduleResolution: "nodenext"? I believe this is achievable by adding correct extensions to the imports in @hey-api/spec-types. Using the same tsdown bundler to build the package might also help.
Reproducible example or configuration
https://stackblitz.com/edit/vitejs-vite-kjtcmthu
OpenAPI specification (optional)
No response
System information (optional)
No response
Description
The new type-only package
@hey-api/spec-typesis not compatible with any client that usemoduleResolution: "nodenext"in theirtsconfig.json.Minimal Reproduce Example
Create a TypeScript project with the following
tsconfig.json:{ "compilerOptions": { "strict": true, "module": "nodenext", "moduleResolution": "nodenext", } }After installing the latest
@hey-api/openapi-ts, the type ofdescriptionis unresolvable and fallback toany.Is it possible to make it compatible with
moduleResolution: "nodenext"? I believe this is achievable by adding correct extensions to the imports in@hey-api/spec-types. Using the sametsdownbundler to build the package might also help.Reproducible example or configuration
https://stackblitz.com/edit/vitejs-vite-kjtcmthu
OpenAPI specification (optional)
No response
System information (optional)
No response