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

docs(themes): update Preloading Fonts section #2837

Merged
merged 4 commits into from
Aug 26, 2024
Merged

docs(themes): update Preloading Fonts section #2837

merged 4 commits into from
Aug 26, 2024

Conversation

amjadorfali
Copy link
Contributor

  • use css property font-face: swap instead of preloading the font to not block rendering

Linked Issue

Closes #2835

Description

Following the previously recommended guide to Preload fonts makes the font loading event block the rendering of the website and heavily affect LCP. Removing it and using the CSS property font-face to handle events on font loading leads to no flickering, and doesn't affect LCP.

Changsets

Instructions: Changesets automate our changelog. If you modify files in /packages, run pnpm changeset in the root of the monorepo, follow the prompts, then commit the markdown file. Changes that add features should be minor while chores and bugfixes should be patch. Please prefix the changeset message with feat:, bugfix: or chore:.

Checklist

Please read and apply all contribution requirements.

  • This PR targets the dev branch (NEVER master)
  • Documentation reflects all relevant changes
  • Branch is prefixed with: docs/, feat/, chore/, bugfix/
  • Ensure Svelte and Typescript linting is current - run pnpm ci:check
  • Ensure Prettier linting is current - run pnpm format
  • All test cases are passing - run pnpm test
  • Includes a changeset (if relevant; see above)

- use css property `font-face: swap` instead of preloading the font to not block rendering
Copy link

changeset-bot bot commented Aug 23, 2024

⚠️ No Changeset found

Latest commit: d8f5dd7

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Aug 23, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
skeleton-docs ✅ Ready (Inspect) Visit Preview Aug 23, 2024 6:07pm

Copy link

vercel bot commented Aug 23, 2024

@amjadorfali is attempting to deploy a commit to the Skeleton Labs Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Contributor

@endigo9740 endigo9740 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @amjadorfali - just a couple small changes needed. Once those are in place I'm happy to merge. Thanks!

.changeset/stupid-lizards-happen.md Outdated Show resolved Hide resolved
@amjadorfali
Copy link
Contributor Author

@endigo9740 Thanks for the feedback. I resolved your comments

@endigo9740 endigo9740 merged commit 4eb0e08 into skeletonlabs:dev Aug 26, 2024
3 of 6 checks passed
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.

Custom Fonts documentation guide to Preloading fonts affects performance and SEO drastically
2 participants