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

Conduct performance audit of Sass @import versus @use for codebase #7525

Closed
joshblack opened this issue Jan 11, 2021 · 2 comments
Closed

Conduct performance audit of Sass @import versus @use for codebase #7525

joshblack opened this issue Jan 11, 2021 · 2 comments
Assignees
Labels
package: components carbon-components

Comments

@joshblack
Copy link
Contributor

We've been heavily considering transitioning over to Sass Modules (@use), in part because it seemed like it would improve our compilation time for projects using our Sass files.

This issue is to conduct a rough performance audit of our current Sass codebase with sass-loader and @import and compare it to a converted codebase with Sass Modules.

@joshblack joshblack added the package: components carbon-components label Jan 11, 2021
@joshblack joshblack self-assigned this Jan 11, 2021
@joshblack
Copy link
Contributor Author

joshblack commented Jan 11, 2021

Baseline with sass-loader and sass implementation with no Carbon styles

Cold start
56533ms

Recompilation
829ms
619ms
767ms

With sass-loader and @import

Cold start
138502ms

Recompilation
50538ms
54899ms
55997ms

Average: 53808ms

With sass-loader and sass implementation

Cold start
95193ms

Recompilation
42531ms
45316ms
40227ms

Average: 42691.33ms

@joshblack
Copy link
Contributor Author

With sass-loader, sass implementation, and @use

Cold start
57257ms

Recompilation
3397ms
2594ms
3236ms

Average
~3075ms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: components carbon-components
Projects
None yet
Development

No branches or pull requests

1 participant