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

Speed up start of the styleguidist #1739

Merged
merged 2 commits into from
Jun 10, 2022
Merged

Speed up start of the styleguidist #1739

merged 2 commits into from
Jun 10, 2022

Conversation

dnlkoch
Copy link
Contributor

@dnlkoch dnlkoch commented Jun 9, 2022

Description

After fiddling around with the current configuration, it looks like the react-docgen-typescript is slowing down the initial build of the styleguidist tremendously while checking the props/types of any parent component (e.g. the extended antd types).

This suggests to skip this check in development mode which will result in decent startup times (before: ~180s. after: ~20 s), BUT the list of props might not be complete. There seems to be a bug while detecting the props of function components as well, see here.

Related issues or pull requests

#1375.

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Dependency updates
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe)
  • I am unsure (we'll look into it together)

Do you introduce a breaking change?

  • Yes
  • No
  • I am unsure (no worries, we'll find out)

Checklist

  • I understand and agree that the changes in this PR will be licensed under the BSD 2-Clause License
  • I have followed the guidelines for contributing
  • The proposed change fits to the content of the code of conduct
  • I have added or updated tests and documentation, and the test suite passes (run npm test locally)
  • I'm lost; why do I have to check so many boxes? Please help!

Copy link
Collaborator

@KaiVolland KaiVolland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two more big issue with styleguidist detected by your work. We should really investigate if we can replace it with something similar.

The PR is a good option anyway as it just changes the dev setup if im right. Feel free to merge.

@dnlkoch
Copy link
Contributor Author

dnlkoch commented Jun 10, 2022

Yes, I agree, we should definitely check for an alternative.

@dnlkoch dnlkoch merged commit 867ca24 into master Jun 10, 2022
@dnlkoch dnlkoch deleted the speed-up-styleguidist branch June 10, 2022 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants