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

Non stable order for keys in CSSModuleExports #291

Open
ArnaudBarre opened this issue Sep 15, 2022 · 2 comments
Open

Non stable order for keys in CSSModuleExports #291

ArnaudBarre opened this issue Sep 15, 2022 · 2 comments

Comments

@ArnaudBarre
Copy link
Contributor

You can play with this example: Add and remove new lines at the end of the playground and see the CSS modules output changed.

I need this to be able to better cache the JS file resulting from the CSS modules exports. This is not a big issue, I can easily resort the keys in JS.

Unrelated: Maybe the blue -> #00f transformation should only be applied when minify is on

@devongovett
Copy link
Member

Rust HashMap does not have a stable order, which is why this happens. We could probably move to indexmap assuming there is no perf regression and the binary size increase isn't too big...

@ArnaudBarre
Copy link
Contributor Author

Yes of course if there is a cost for everyone I can ensure the stable on my side

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

2 participants