Closed
Description
Q&A (please complete the following information)
- OS: macOS
- Browser: chrome
Content & configuration
Swagger/OpenAPI definition:
https://petstore.swagger.io/v2/swagger.json
Swagger-UI configuration options:
SwaggerUI({
filter: true
})
?filter=true
Describe the bug you're encountering
When the query parameter filter=true is used, then the filter field should be shown with all of the endpoints.
But in src/core/components/operations.jsx
the result of the code:
let filter = layoutSelectors.currentFilter()
is that the filter
field will contain a string with value "true".
Since this value is a string and not a boolean, the following condition:
if (filter !== true)
is true (it should be false), and the filtering is applied.
To reproduce...
Steps to reproduce the behavior:
Expected behavior
The swagger-ui with a filter field and all of the endpoint is shown.
Actual behavior
The swagger-ui with a filter field and no endpoints is shown. The endpoints are filtered by the text "true".