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

Bug: Ordering inconsistent when using multiple inputs in rollup #461

Open
kylemellander opened this issue Oct 1, 2024 · 0 comments
Open

Comments

@kylemellander
Copy link

Summary

There is code to order css that is imported in a deterministic order based on the order that it is imported into files. This works great when there is only 1 input file, but when multiple input files are used in rollup, then the output ends up putting all css from the non-first inputs at the top in resolve order (as long as it is not as well imported into the first input). This creates inconsistent outputs that can cause overrides to work incorrectly.

Replication

https://stackblitz.com/edit/vitejs-vite-bgp6mc?file=rollup.config.js&view=editor

  1. run npm run build

Expected Results

The resulting dist/index.css should not put the css from the second input before the shared css.

Actual Results

The second inputs non-shared css is placed first, and then everything is ordered as intended.

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

No branches or pull requests

1 participant