Surnet/swagger-jsdoc

Wrong "Supported Specifications" list in the README

Closed this issue · 1 comments

Describe the bug
The README says openapi 3.x is supported, however, using 3.1.0 leads to "Unable to render this definition" error, and changing it to 3.0.0 makes it work. The error was quite confusing because I didn't think this could be a swagger-jsdoc issue according to what's written in the README.

To Reproduce
Steps to reproduce the behavior:
This is a sample definition that doesn't work with openapi 3.1.0:

/**
 * @swagger
 * components:
 *   schemas:
 *     Todo:
 *       type: object
 *       required:
 *         - id
 *         - text
 *         - isDone
 *       properties:
 *         id:
 *           type: string
 *         text:
 *           type: string
 *         isDone:
 *           type: boolean
 *         isDeleted:
 *           type: boolean
 *         medias:
 *           type: array
 *           items:
 *             $ref: '#/components/schemas/TodoMedia'
# Rest omitted for bravity

but works with 3.0.0.

Expected behavior
Since the README says 3.x is supported, I expected this to work with 3.1.0 too.

Desktop (please complete the following information):

  • OS: Windows 10 v22H2-19045
  • Browser: Chrome v110.0
stale commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.