swagger-api / swagger-api/swagger-ui
docExpansion add one more option
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 29k
- Forks
- 9.3k
- Avg merge
- 2d 23h
- Merged PRs (30d)
- 25
Description
Would you consider adding one more option for the docExpansion
Currently there are these settings:
None
List
Full
I wish there was also 'First'
'First', would just open the first tag in the list. With some of our API's getting larger, I like the ability to have it collapsed, but it's nice to be able to see the first tag section open on load. In our case it is our Authentication Section which is first and works well to be first.
?
Thanks!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the docExpansion entry point and the existing handling for None, List, and Full, then inspect nearby tests if available. Implement the requested First behavior so the first tag section is open on load while the other modes remain unchanged, and verify the behavior in the existing Swagger UI test or browser workflow.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100