swagger-api / swagger-api/swagger-ui
Allow more selective configuration on where syntax highlighting should be used
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 29k
- Forks
- 9.3k
- Avg merge
- 2d 23h
- Merged PRs (30d)
- 25
Description
Is your feature request related to a problem?
We use OpenAPI for an API which does some backend calculations and deliver a result to the frontend based on its request.
The request is relatively small. Especially when you manually enter it in the "Try it out" mode. Also the example for the response is pretty small. The only thing that is really huge is the actual response if it comes from the server.
I really like to have syntax highlighting for as much as possible. It makes reading the JSON much easier. But for the big response JSON the whole syntax highlighting process just takes way too long. This is the reason why I currently have syntax highlighting completely off. Usability is more important than nice look.
Describe the solution you'd like
It would be great if enabling or disabling syntax highlighting was more selective. Actually I want to disable it for the result in "Try it out" only as that's what takes too long. Everywhere else I would love to have some syntax highlighting.
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 tracing how syntax highlighting is configured and applied to the Try it out response and to the smaller request and example views. Define a selective setting that disables highlighting only for large result responses while retaining it elsewhere, then verify the behavior with representative small and large JSON responses.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100