Name flag is not respected when --modular is also provided
When I run:
swagger-typescript-api --extract-enums --modular -p ./app/api/openapi.json -o ./app/api/sdk -n generated.server.ts
These files are generated
app/api/sdk/data-contracts.ts
app/api/sdk/http-client.ts
app/api/sdk/Api.ts
It looks like the -n flag is discarded when used with the --modular flag. I couldn't figure out any way to change the output file names when using the --modular flag from the readme.
I would expect app/api/sdk/Api.ts to be named app/api/sdk/generated.server.ts based on the -n flag.
This issue also affects the --api-class-name argument.
That's strange that it generated Api.ts when you used the --modular flag. Since it should have generated a separate file for each resource; that's what it does for me.
For example, when I use the Swagger pet store example
npx swagger-typescript-api -p https://petstore3.swagger.io/api/v3/openapi.json -o ./api --modular
It generates
/api/data-contracts.ts
/api/http-client.ts
/api/Pet.ts
/api/Store.ts
/api/User.ts
It does this with or without the -n index.ts flag.
I'm facing the same problem, but using the API code. Even after I defined the name property the generated file is "Api.ts"