jensoleg/swagger-ui

Not working enum references

Opened this issue · 0 comments

Hi everybody
I have problem with enum references. I use referencing like this:

swagger: '2.0'
info:
  version: 1.0.0
  title: Pets Store
paths:
  /pets:
    get:
      responses:
        200:
          description: Returns all the pets
          schema:
            $ref: '#/definitions/List'
        201:
          description: Returns all the pets
          schema:
            $ref: '#/definitions/Set'

definitions:
  List:
    type: string
    enum: &my-list
      - one
      - two
      - three
  Set:
    type: string
    enum: *my-list

So declaration has name started with & and reference starts with * . It works well on swagger but does not work on your UI. I get well response sample but on response schema i have:

Can be m, y, -, l, i, s, t
instead of referenced enums.