Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

perf(vite): do not resolve module field for packages #2636

Merged
merged 5 commits into from
Jan 11, 2022

Conversation

antfu
Copy link
Member

@antfu antfu commented Jan 7, 2022

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

https://github.com/vitejs/vite/blob/04016df8beb7110ad2087ada8e1abbefdbd70254/packages/vite/src/node/constants.ts#L3-L7

We have confirmed this works for Vitest and sloved many issues we had.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify
Copy link

netlify bot commented Jan 7, 2022

βœ”οΈ Deploy Preview for nuxt3-docs ready!

πŸ”¨ Explore the source changes: e0ca661

πŸ” Inspect the deploy log: https://app.netlify.com/sites/nuxt3-docs/deploys/61dddc36364f7400084e51d3

😎 Browse the preview: https://deploy-preview-2636--nuxt3-docs.netlify.app

packages/vite/src/server.ts Outdated Show resolved Hide resolved
Co-authored-by: pooya parsa <pyapar@gmail.com>
@pi0 pi0 merged commit a2e2e04 into main Jan 11, 2022
@pi0 pi0 deleted the pref/vite-resolve-fields branch January 11, 2022 19:37
@pi0 pi0 restored the pref/vite-resolve-fields branch January 12, 2022 09:34
@pi0
Copy link
Member

pi0 commented Jan 12, 2022

Changes temporary reverted because of regression discussed in nuxt/nuxt#13196

@antfu
Copy link
Member Author

antfu commented Jan 12, 2022

Ah sorry for that. I think it also requires some additional logic to interop the default, I will include that in the upcoming refactor of using on-demand module evaluation

danielroe added a commit that referenced this pull request Jan 13, 2022
danielroe added a commit that referenced this pull request Jan 17, 2022
@antfu antfu deleted the pref/vite-resolve-fields branch February 18, 2022 05:40
@danielroe danielroe added the 3.x label Jan 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants