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

chore(ui): use local fonts instead of CDN. WF-27 #487

Merged
merged 1 commit into from
Jul 8, 2024

Conversation

madeindjs
Copy link
Collaborator

@madeindjs madeindjs commented Jul 6, 2024

Use Fontsource with NPM instead of relying on https://fonts.google.com

Try to spot the difference (I don't see any 🧐 )

before after
Screenshot 2024-07-06 at 22-36-55 Hello Writer Framework Builder Screenshot 2024-07-06 at 22-36-36 Hello Writer Framework Builder

@ramedina86
Copy link
Collaborator

Hey, looks good, I didn't know about Fontsource. Neat to be able to manage via npm.

Can we look into only using local if CDN fails?

https://stackoverflow.com/questions/7383163/how-to-fallback-to-local-stylesheet-not-script-if-cdn-fails

@FabienArcellier
Copy link
Collaborator

I love it. Everything is served through the local server. The cache is used properly on the browser, so I would advocate to keep local diffusion instead of using cdn.

(left: dev version, right: version in the PR)
image

(cache usage, the file is only downloaded once)
image

@ramedina86 ramedina86 merged commit 56fc0dc into writer:dev Jul 8, 2024
16 checks passed
This pull request was closed.
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

Successfully merging this pull request may close these issues.

3 participants