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

[Feature]: meteor-component-library css bundle is huge due to fonts #279

Closed
1 task done
cyl3x opened this issue Sep 5, 2024 · 2 comments · May be fixed by #284
Closed
1 task done

[Feature]: meteor-component-library css bundle is huge due to fonts #279

cyl3x opened this issue Sep 5, 2024 · 2 comments · May be fixed by #284
Labels
enhancement New feature or request

Comments

@cyl3x
Copy link
Contributor

cyl3x commented Sep 5, 2024

Package

@meteor/component-library

Package version

3.11.0

Link to minimal reproduction

https://stackblitz.com/edit/vitejs-vite-xmwwbk?file=src%2Fmain.js

Steps to reproduce

  • Create a vue + vite project
  • Install the meteor-component-library
  • Add a import '@shopware-ag/meteor-component-library/dist/style.css';
  • Build the app

Actual behavior

The resulting css file is about ~4.5MB (~3.5MB gzipped) according to vite. Removing the inlined fonts will reduce the css bundle down to ~180KB (~25KB gzipped).

Expected behavior

Fonts aren't inlined as base64 within the same css file, but bundled separately to allow more selective import. Bundling 10 different fonts feels clumsy, and I'd like to be able to bundle, say, regular fonts only when I don't have bold or italic text.

System Info

No response

Any additional comments?

No response

Code of Conduct

@cyl3x cyl3x added type: bug 🐛 Something isn't working enhancement New feature or request and removed type: bug 🐛 Something isn't working labels Sep 5, 2024
@cyl3x cyl3x changed the title [Bug]: meteor-component-library css bundle is huge due to fonts [Feature]: meteor-component-library css bundle is huge due to fonts Sep 5, 2024
@shyim
Copy link
Member

shyim commented Dec 18, 2024

the attached PR is not merged, open it up again?

@bojanrajh
Copy link
Contributor

There's another PR that was merged, but is not released yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants