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] Check link validity in PR #6497

Merged
merged 8 commits into from
Oct 24, 2022
Merged

Conversation

alexfauquette
Copy link
Member

@alexfauquette alexfauquette commented Oct 13, 2022

Reuse helper proposed in mui/material-ui#34588

Remaining: wait for core release, to update monorepo

@mui-bot
Copy link

mui-bot commented Oct 13, 2022

Messages
📖 Netlify deploy preview: https://deploy-preview-6497--material-ui-x.netlify.app/

These are the results for the performance tests:

Test case Unit Min Max Median Mean σ
Filter 100k rows ms 506.6 1,000.7 581.6 738.48 176.156
Sort 100k rows ms 576.7 1,054.6 576.7 915.2 173.703
Select 100k rows ms 178.7 277.1 229.5 230.78 34.801
Deselect 100k rows ms 127 210.1 183.2 179.12 28.892

Generated by 🚫 dangerJS against d676b5f

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Oct 13, 2022
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Oct 13, 2022
@oliviertassinari oliviertassinari added the docs Improvements or additions to the documentation label Oct 14, 2022
@oliviertassinari
Copy link
Member

oliviertassinari commented Oct 14, 2022

Does the logic find this 404 link on HEAD?

You can find the documentation in the [Validation page](/react-date-pickers/validation/)

(there is the same 404 on a couple of other pages)

@alexfauquette
Copy link
Member Author

alexfauquette commented Oct 14, 2022

Yes 🎉


Report after going on HEAD

Broken links found by `yarn docs:link-check` that exist:

- https://mui.com/blog/material-ui-v4-is-out/#premium-themes-store-✨
- https://mui.com/react-date-pickers/validation
- https://mui.com/size-snapshot
- https://mui.com/x/react-data-grid/migration-v4
- https://mui.com/x/react-date-pickers/migration-lab

A detailed report (I removed the false positive)

https://mui.com/react-date-pickers/validation
used in
- data/date-pickers/date-picker/date-picker.md
- data/date-pickers/date-range-picker/date-range-picker.md
- data/date-pickers/date-time-picker/date-time-picker.md
- data/date-pickers/time-picker/time-picker.md
available anchors on the same page:

https://mui.com/x/react-data-grid/migration-v4
used in
- ../node_modules/@mui/monorepo/docs/pages/blog/mui-x-v5.md
available anchors on the same page:

https://mui.com/x/react-date-pickers/migration-lab
used in
- ../node_modules/@mui/monorepo/docs/pages/blog/lab-date-pickers-to-mui-x.md
- ../node_modules/@mui/monorepo/docs/pages/blog/lab-date-pickers-to-mui-x.md
available anchors on the same page:

Done in 4.41s.

@alexfauquette alexfauquette marked this pull request as ready for review October 14, 2022 16:04
@alexfauquette
Copy link
Member Author

It's weird. The import was fine with yarn link but it does not work now with the monorepo

From what I understand, the file /node_modules/@mui/monorepo/docs/scripts/reportBrokenLinks.js is not able to resolve @mui/markdown

Doing the following modification in the node_module file solves the problem

-const { createRender } = require('@mui/markdown');
+const { createRender } = require('../packages/markdown');

So a solution could be to this modification in the material-ui repository.

Maybe there is another solution, but it's out of my knowledge about package alias

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Oct 20, 2022
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@oliviertassinari
Copy link
Member

oliviertassinari commented Oct 21, 2022

@alexfauquette I have pushed a fix for it, the tricky aspect is that there is a lot happening beyond the scene that is hard to pinpoint the origin of where it starts and where it ends. I hope mui/material-ui#34841 (comment) and my commit bring a bit more clarity on how this fits together. I moved the script execution location to use the babel config of the root that is optimized to run scripts from the mono repo, while the babel config of the docs is designed to build the docs pages.

The CI is still not green but I think a rebase on HEAD would solve the problem, taking #6549 in.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Oct 21, 2022
@alexfauquette alexfauquette merged commit 540bedd into mui:next Oct 24, 2022
@alexfauquette alexfauquette deleted the fix-links branch October 24, 2022 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants