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

chore: tweak external to improve startup #5

Closed
wants to merge 1 commit into from

Conversation

hi-ogawa
Copy link
Owner

@hi-ogawa hi-ogawa commented Jul 6, 2024

When running DEBUG=vite:transform pnpm dev, I noticed the excessive amount of transforms and it looks like externalizing some of it would help startup. Still react related deps cannot be externalized, so they needs to be in optimizeDeps explicitly.

# before
  VITE v5.3.1  ready in 229 ms

  ➜  Local:   http://localhost:5173/
  ➜  Network: use --host to expose
  ➜  press h + enter to show help
  --> GET /
  <-- GET / 200 1.2s

# after
  --> GET /
  <-- GET / 200 959ms

It also interesting to compare for raw flight request http://localhost:5173/__f.data since this doesn't involve css crawling.

This was referenced Jul 6, 2024
Copy link
Owner Author

hi-ogawa commented Jul 6, 2024

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @hi-ogawa and the rest of your teammates on Graphite Graphite

@hi-ogawa
Copy link
Owner Author

Now noExternal is refined so this shouldn't be necessary

@hi-ogawa hi-ogawa closed this Jul 26, 2024
@hi-ogawa hi-ogawa deleted the chore-optimize-deps branch July 26, 2024 07:05
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.

1 participant