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

fix(ssr): hoist re-exports with imports #12530

Merged
merged 1 commit into from
Mar 22, 2023
Merged

Conversation

bluwy
Copy link
Member

@bluwy bluwy commented Mar 22, 2023

Description

Supersedes #12527
Should fix ecosystem-ci for nuxt and plugin-react

When hoisting the import statement generated by re-exports by Vite, hoist the other re-exports code together with the import statement.

The snapshot diff should show how this works now.

Additional context

Should also fix the test at #12528, which I've verified locally.

cc @sapphi-red


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

Before submitting the PR, please make sure you do the following

  • Read the Contributing Guidelines.
  • Read the Pull Request Guidelines and follow the PR Title Convention.
  • Check that there isn't already a PR that solves the problem the same way to avoid creating a duplicate.
  • Provide a description in this PR that addresses what the PR is solving, or reference the issue that it solves (e.g. fixes #123).
  • Ideally, include relevant tests that fail without this PR but pass with it.

@bluwy bluwy added p3-minor-bug An edge case that only affects very specific usage (priority) feat: ssr labels Mar 22, 2023
@stackblitz
Copy link

stackblitz bot commented Mar 22, 2023

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

@bluwy bluwy changed the title Fix ssr export hoist fix(ssr): hoist re-exports with imports Mar 22, 2023
@patak-dev
Copy link
Member

/ecosystem-ci run

@vite-ecosystem-ci
Copy link

vite-ecosystem-ci bot commented Mar 22, 2023

📝 Ran ecosystem CI: Open

suite result
astro ❌ failure
histoire ❌ failure
iles ✅ success
ladle ✅ success
laravel ✅ success
marko ✅ success
nuxt ✅ success
previewjs ✅ success
qwik ✅ success
rakkas ✅ success
sveltekit ✅ success
vite-plugin-ssr ✅ success
vite-plugin-react ✅ success
vite-plugin-react-pages ✅ success
vite-plugin-react-swc ✅ success
vite-plugin-svelte ✅ success
vite-plugin-vue ✅ success
vite-setup-catalogue ✅ success
vitepress ✅ success
vitest ✅ success
windicss ✅ success

@patak-dev patak-dev merged commit 45549e4 into main Mar 22, 2023
@patak-dev patak-dev deleted the fix-ssr-export-hoist branch March 22, 2023 08:36
@sapphi-red
Copy link
Member

Oh, that was quick. Awesome 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat: ssr p3-minor-bug An edge case that only affects very specific usage (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants