xavianaxw/sass-fonts

Allow webfonts to use weight

Closed this issue · 1 comments

Defining webfonts now can be done like so...

@font-face {
  font-family: "ap-letter";
  font-style: normal;
  font-weight: 400;
  src:  url("/fonts/letter-regular-webfont.woff2") format("woff2"),
        url("/fonts/letter-regular-webfont.woff") format("woff");
}

@font-face {
  font-family: "ap-letter";
  font-style: normal;
  font-weight: 500;
  src:  url("/fonts/letter-medium-webfont.woff2") format("woff2"),
        url("/fonts/letter-medium-webfont.woff") format("woff");
}

with this in mind we can allow webfonts to pass through weight for determining which font to use.

Solved with v2.0.0 release

Source:
42db882