Skip to content
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

Underscores in interface names with specific schema definition. #65

Closed
Nalhin opened this issue Jul 7, 2020 · 2 comments
Closed

Underscores in interface names with specific schema definition. #65

Nalhin opened this issue Jul 7, 2020 · 2 comments
Assignees
Labels
invalid This doesn't seem right next release

Comments

@Nalhin
Copy link

Nalhin commented Jul 7, 2020

Spring automatically generates schema definitions with generic types (see the example for details).
This causes the typescript interfaces to contain underscores in place of "«" symbols when such a schema is used.

Current result:
Page_TemplateResponseDto_

Expected result:
PageTemplateResponseDto

OA version - 2.0

Example schema:

{
   "Page«TemplateResponseDto»":{
      "type":"object",
      "properties":{
         "content":{
            "type":"array",
            "items":{
               "$ref":"#/definitions/TemplateResponseDto"
            }
         },
         "empty":{
            "type":"boolean"
         },
         "first":{
            "type":"boolean"
         },
         "last":{
            "type":"boolean"
         },
         "number":{
            "type":"integer",
            "format":"int32"
         },
         "numberOfElements":{
            "type":"integer",
            "format":"int32"
         },
         "pageable":{
            "$ref":"#/definitions/Pageable"
         },
         "size":{
            "type":"integer",
            "format":"int32"
         },
         "sort":{
            "$ref":"#/definitions/Sort"
         },
         "totalElements":{
            "type":"integer",
            "format":"int64"
         },
         "totalPages":{
            "type":"integer",
            "format":"int32"
         }
      },
      "title":"Page«TemplateResponseDto»"
   }
}
@js2me js2me self-assigned this Jul 7, 2020
@js2me js2me added invalid This doesn't seem right next release labels Jul 7, 2020
@js2me
Copy link
Member

js2me commented Jul 7, 2020

@Nalhin thanks for this issue!
I'll fix that in the next release (next day, GMT+3)

@js2me js2me mentioned this issue Jul 13, 2020
@js2me
Copy link
Member

js2me commented Jul 13, 2020

It should be fixed in 1.11.0 release

@js2me js2me closed this as completed Jul 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right next release
Projects
None yet
Development

No branches or pull requests

2 participants