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

perf: don't recalculate path.dirname(mod.file) #15623

Merged
merged 1 commit into from
Jan 19, 2024
Merged

Conversation

patak-dev
Copy link
Member

Description

Small change to avoid recalculating path.dirname on every iteration


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

Copy link

stackblitz bot commented Jan 16, 2024

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

@patak-dev patak-dev added the performance Performance related enhancement label Jan 16, 2024
@patak-dev patak-dev merged commit e459be4 into main Jan 19, 2024
15 checks passed
@patak-dev patak-dev deleted the perf/cache-mod-dirname branch January 19, 2024 09:19
@patak-dev
Copy link
Member Author

@sapphi-red, by the way, the path.relative call here is a bit costly when looking at the profiles. I feel like we could optimize it somehow but I couldn't find a good way to do so. Just in case you have some ideas in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Performance related enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants