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

Use web fonts on web containers #1523

Closed
brc-dd opened this issue Oct 21, 2022 · 3 comments · Fixed by #1531
Closed

Use web fonts on web containers #1523

brc-dd opened this issue Oct 21, 2022 · 3 comments · Fixed by #1531
Labels
build Related to the build system enhancement New feature or request theme Related to the theme

Comments

@brc-dd
Copy link
Member

brc-dd commented Oct 21, 2022

Context: Currently we emit a bunch of font files to dist while building. This causes error in StackBlitz if the user doesn't have subscription.

Solution: Add an option to use Inter from Google Fonts. And enable it by default on webcontainers. Env can be checked like this.

@brc-dd brc-dd added enhancement New feature or request build Related to the build system theme Related to the theme labels Oct 21, 2022
@rijkvanzanten
Copy link
Contributor

rijkvanzanten commented Nov 4, 2022

@brc-dd We're now pinging Google's servers with the user's IP address as fonts are loaded client side. If I'm not mistaken, there were some privacy concerns with that, especially around GDPR in the European markets 🤔

https://www.theregister.com/2022/01/31/website_fine_google_fonts_gdpr/

Should we think through a way to opt-out of relying on Google-hosted fonts or potentially allowing that to be overridden so the font can be hosted on a secure CDN?

@brc-dd
Copy link
Member Author

brc-dd commented Nov 4, 2022

Just to clarify: we don't use Google Fonts by default. They are only used inside webcontainers (on StackBlitz) or if the user has explicitly set that option. I think you shouldn't set that on production?

@rijkvanzanten
Copy link
Contributor

Ahhh gotcha! My bad, didn't catch the bundler plugin that strips it out based on the comments 🙂

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
build Related to the build system enhancement New feature or request theme Related to the theme
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants