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

revert: starter vite config server bundle optimizations #6265

Merged
merged 1 commit into from
May 7, 2024

Conversation

thejackshelton
Copy link
Member

@thejackshelton thejackshelton commented May 7, 2024

Overview

The commented SSR configuration in vite.config.ts intended to enhance server code bundling for production builds by including all development dependencies and excluding specified production dependencies to optimize the server bundling.

This has led to consumers adding packages in the wrong location, and as a result these packages do not work in production.

This PR comments out that code, and labels it as an advanced config for when you understand which dependencies should be consumed either as a dependency, or dev dependency.

In the future, I believe we should uncomment this code by default, but only when better error handling is present, as it was difficult to debug. For example, a CLI message that tells us whether the wrong dependency was bundled or not.

For more context see:
https://discord.com/channels/990511757091033108/1040763063533588562/1237190861985550376

from the Qwikifiers discord

Original change:
#5961

cc @wmertens

Checklist:

  • My code follows the developer guidelines of this project
  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • Added new tests to cover the fix / functionality

Copy link
Member

@wmertens wmertens left a comment

Choose a reason for hiding this comment

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

LGTM

@thejackshelton thejackshelton changed the title revert: bundle optimization improvements revert: starter vite config server bundle optimizations May 7, 2024
@wmertens wmertens enabled auto-merge (squash) May 7, 2024 15:26
@wmertens wmertens merged commit 51e9924 into main May 7, 2024
29 checks passed
@wmertens wmertens deleted the revert-bundle-optimization branch May 7, 2024 15:37
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.

None yet

2 participants