Redocly / Redocly/redoc

Redoc taking lot of time to render documentation

Open
#1,814 7 comments 1 reaction 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 bug
Redoc taking lot of time to load the page, Its taking approx 1 min to load the documentation

Expected behavior
Redoc renders docs in few seconds

Additional context
Browser: chrome, firefox

We are getting 12000+ warnings mentioned below in console and page is rendered only after 1 min, till then it was just showing loading icon. And the memory used by javascript VM instance is 1875MB

Size of spec(yaml): 42KB

Warning messages:

(index):16 Incompatible types in allOf at "#/components/schemas/FormFieldComponent/oneOf/7/properties/label": "object" and "string"
value @ (index):16
(index):16 Incompatible types in allOf at "#/components/schemas/FormFieldComponent/oneOf/7/properties/hint": "object" and "string"
value @ (index):16
(index):16 Incompatible types in allOf at "#/components/schemas/FormFieldComponent/oneOf/7/properties/placeholder": "object" and "string"

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 reproducing the delay in Chrome or Firefox with the reported 42 KB OpenAPI YAML and inspect the 12,000+ allOf warnings at the FormFieldComponent schema path. Compare rendering time and JavaScript memory usage before and after investigation; the issue names no repository file or test, so a regression-test location must be identified during the work.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi, react, typescript
Domain
documentation, frontend, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.