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

feat: enable fs.cachedChecks by default #15704

Merged
merged 3 commits into from
Jan 25, 2024

Conversation

patak-dev
Copy link
Member

Description

fs.cachedChecks has been available and opt-in from vite@5.0.8.

See:

In Windows, we have:

  • tryFsResolve: 179.71ms -> 13.16ms (~14x faster)
  • resolveId: 234ms -> 50ms (~4.7x faster)
  • 5% overall

This PR switches the flag to be enabled by default.

We also consider that if there is custom watch ignore options, the user is opting into not watching these files not only HMR but also for resolving.

In future PRs we need to:

  • move the public files fs caching implementation to use this new cache
  • re-define the fs cache root to be the root of the monorepo instead of root to better support that use case
  • decide if sharing cached trees is worth the extra complexity: perf: cached fs utils with shared trees #15294

What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

Copy link

stackblitz bot commented Jan 24, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@patak-dev patak-dev added p3-significant High priority enhancement (priority) performance Performance related enhancement labels Jan 24, 2024
@patak-dev patak-dev merged commit a05c709 into main Jan 25, 2024
15 checks passed
@patak-dev patak-dev deleted the feat/enable-fs-cached-checks-by-default branch January 25, 2024 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p3-significant High priority enhancement (priority) performance Performance related enhancement
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants