Redocly / Redocly/redoc

Hide code samples panel

Open
#2,461 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Type: Enhancement
Dominant language
TypeScript
Stars
25.9k
Forks
2.4k
Avg merge
13h 10m
Merged PRs (30d)
4

Description

Describe the problem to be solved
We would like to be able to disable/hide the code samples panel for specific operation. For now we set x-codeSamples to empty but it doesn't give the ideal UI

Describe the solution you'd like
It could be something similar to x-hideTryItPanel flag.

Describe alternatives you've considered
Putting x-codeSamples with source: "" which is not ideal but we can live with it

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the existing x-hideTryItPanel handling and the code samples panel in the Redoc frontend. Add an equivalent per-operation way to hide code samples without requiring an empty x-codeSamples value, then verify that the panel remains available for operations without the flag.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.