Skip to content

[REQ] Add a way to split models into multiple folders based on a criteria such as (request or response) #21696

@rami-foo

Description

@rami-foo

Is your feature request related to a problem? Please describe.

I think that would be really beneficial for a lot of generators since it is common to have a requests folder and a response folder or DTO folder. EG company conventions

Describe the solution you'd like

I already make a solution that involved mapping each modelName to a Type by recursively going through the paths.
then overriding the toModelImport to track each model and change the import. I also needed to update the modelFileName to contain the location of the folder (not modelFileFolder because that is static and can't be influenced by the file name)

there is also the issue of "Orphan" models that are part of requests and responses because they are referenced in a Model but aren t a request in of themselves. Which needed to be dealt with and they were put in a 3rd separate folder

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions