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

refactor: esbuild plugin config logic #12493

Merged
merged 1 commit into from Mar 21, 2023

Conversation

patak-dev
Copy link
Member

Description

Simplify the config logic of the vite:esbuild. It should also be a bit more performant, but it is too small to mark this as a perf PR. Avoiding changing the shape of the config through deletes could help though.


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

@stackblitz
Copy link

stackblitz bot commented Mar 20, 2023

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

@patak-dev patak-dev added the p1-chore Doesn't change code behavior (priority) label Mar 20, 2023
Comment on lines -174 to -176
delete resolvedOptions.include
delete resolvedOptions.exclude
delete resolvedOptions.jsxInject
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These were needed because there is a cast here: https://github.com/vitejs/vite/pull/12493/files#diff-6d149ac9706cd508b52db0c059a0f01d670620a9a5a73cd7b122ce62b6b69471R205, from our own extended options. These fields are no longer present when calling transformWithEsbuild after the changes in this PR.

@patak-dev patak-dev merged commit 45b5b0f into main Mar 21, 2023
11 checks passed
@patak-dev patak-dev deleted the refactor/esbuild-plugin-config-logic branch March 21, 2023 06:44
@sapphi-red
Copy link
Member

/ecosystem-ci run

@vite-ecosystem-ci
Copy link

vite-ecosystem-ci bot commented Mar 21, 2023

📝 Ran ecosystem CI: Open

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

@patak-dev
Copy link
Member Author

@sapphi-red here is the run against the merged commit: https://github.com/vitejs/vite-ecosystem-ci/actions/runs/4481055968

@sapphi-red sapphi-red restored the refactor/esbuild-plugin-config-logic branch March 21, 2023 15:48
@sapphi-red sapphi-red deleted the refactor/esbuild-plugin-config-logic branch March 21, 2023 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p1-chore Doesn't change code behavior (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants