Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[docs-infra] Prevent 404 from demo to API pages #252

Open
alexfauquette opened this issue Feb 5, 2024 · 0 comments
Open

[docs-infra] Prevent 404 from demo to API pages #252

alexfauquette opened this issue Feb 5, 2024 · 0 comments
Labels
scope: docs-infra Specific to the docs-infra product

Comments

@alexfauquette
Copy link
Member

alexfauquette commented Feb 5, 2024

The docs:api script is failing if an API page does not have a demonstration associated:
https://github.com/mui/material-ui/blob/59addf0b5519bd2f6f088031f7a71cc6ef0f40bf/packages/api-docs-builder/ApiBuilders/ComponentApiBuilder.ts#L745

But we miss the opposite check: make sure that all API pages listed in a demo exist.

This is not a straight forward modification because demos/api links are verified when creating an API page.
We should move this logic to get an overview of all the "demos to api" links to ensure they all exist.

Either by modify the docs:api such that componentsInfo.getDemos() coudl be replaced by an object { [project]: { [component]: demos }}

Such that by listing all the components with API page we can verify if some are missing

The other solution is to add the parsing of the components: .... in the script docs:link-check

Search keywords:

Search keywords:

@github-actions github-actions bot added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Feb 5, 2024
@alexfauquette alexfauquette added scope: docs-infra Specific to the docs-infra product and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Feb 5, 2024
@oliviertassinari oliviertassinari transferred this issue from mui/material-ui Nov 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: docs-infra Specific to the docs-infra product
Projects
Status: Backlog
Development

No branches or pull requests

1 participant