Redocly / Redocly/redocly-cli

command preview-docs / build-docs, use installed redoc.standalone.js rather than fetching from CDN ?

Open
#1,035 8 comments 20 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

p3 Type: Idea
Dominant language
TypeScript
Stars
1.5k
Forks
228
Avg merge
1d 14h
Merged PRs (30d)
48

Description

Describe the problem to be solved
I use the command redocly preview-docs / build-docs to preview and build redoc html.
But my doc html will be served in a intranet network, which can NOT access the internet and therefor can't load the script file:
https://cdn.redoc.ly/redoc/latest/bundles/redoc.standalone.js.

Describe the solution you'd like
I install redoc in my project , and I hope redocly can use local redoc.standalone.js rather than fetching from CDN.

Describe alternatives you've considered
Even though I can modify the html build from command build-docs to use a local js. I still hope preview-docs / build-docs can use the same redoc.standalone.js.

Additional context
No configuration option were found relatived to such approach.

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 tracing the redocly preview-docs and build-docs command entry points and how they currently reference https://cdn.redoc.ly/redoc/latest/bundles/redoc.standalone.js. Verify how an installed local redoc.standalone.js can be selected for both commands; done means preview and generated HTML work without internet access.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
cli, documentation
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.