orval is able to generate client with appropriate type-signatures (TypeScript) from any valid OpenAPI v3 or Swagger v2 specification, either in yaml or json formats. 🍺
4. Run `npx orval --config orval.config.ts`
5. Observe that for `.generated/types/error.ts` and `.generated/types/pet.ts` the type alias exports are missing for `Error` and `Pet`.
## What happens?
Some schema files are generated with missing type alias exports. e.g.
`.generated/types/pet.ts`:
```ts
/**
* Generated by orval v6.22.1 🍺
* Do not edit manually.
* Swagger Petstore
* OpenAPI spec version: 1.0.0
*/
import type { Pet } from './petstore.yml/pet';
What were you expecting to happen?
File to be generated with type alias exports, e.g.
.generated/types/pet.ts
/**
* Generated by orval v6.22.1 🍺
* Do not edit manually.
* Swagger Petstore
* OpenAPI spec version: 1.0.0
*/
import type { Pet as PetstoreYmlPet } from './petstore.yml/pet';
export type Pet = PetstoreYmlPet;
What are the steps to reproduce this issue?
petstore.yml
file using https://github.com/OAI/OpenAPI-Specification/blob/main/examples/v3.0/petstore.yamlopenapi.yml
file using cross-file$ref
s as:orval.config.ts
as:export default defineConfig({ api: { input: { target: path.join(__dirname, "openapi.yml"), }, output: { mode: "tags", target: ".generated/index.ts", schemas: ".generated/types", client: "react-query", }, }, });
What were you expecting to happen?
File to be generated with type alias exports, e.g.
.generated/types/pet.ts
Any logs, error output, etc?
N/A
Any other comments?
This appears to have been broken since v6.17.0 with the change introduced here: https://github.com/anymaniax/orval/commit/3e46854fbb3965c8ac4aa46ebcd361d8fa113d30#diff-05706d9e4229657eff2f993788e246673cf6928f31befd281e0e484bad755240R66
What versions are you using?
Operating System: macOS Sonoma 14.1.2 Package Version: v6.22.1 (issue since v6.17.0) Browser Version: N/A