Skip to content
This repository has been archived by the owner on May 17, 2019. It is now read-only.

Add font-display: fallback to font faces #130

Merged
merged 1 commit into from
Nov 14, 2018
Merged

Add font-display: fallback to font faces #130

merged 1 commit into from
Nov 14, 2018

Conversation

angus-c
Copy link
Contributor

@angus-c angus-c commented Nov 14, 2018

Resolves #131

This allows developers to optionally skip withFontLoading HOC in favor of just adding fontFamily in styletron definition. It is a workaround for #108, pending a refactor of the HOC API.

Note: where font-display is not supported (currently Edge, Android plus older browsers) skipping the HOC may result in some old fashioned FOIC and FOUT, though this can be minimized by configuring for maximum preload (set preloadDepth to 0 in src/font/config.js)

@codecov
Copy link

codecov bot commented Nov 14, 2018

Codecov Report

Merging #130 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #130   +/-   ##
=======================================
  Coverage   49.21%   49.21%           
=======================================
  Files           9        9           
  Lines         128      128           
  Branches       21       21           
=======================================
  Hits           63       63           
  Misses         65       65
Impacted Files Coverage Δ
src/generate-font-faces.js 100% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b047df4...68e9f4b. Read the comment docs.

@angus-c angus-c merged commit 3d41a03 into master Nov 14, 2018
@AlexMSmithCA AlexMSmithCA mentioned this pull request Nov 27, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants