heinetz: Fonts einbinden

Beitrag lesen

@@heinetz

<head>
    <style>
        @font-face {
            src: url('/fonts/Lato-Light-7244318390.woff2') format('woff2');
            font-family: 'Lato';
            font-style: normal;
            font-weight: normal;
        }
    </style>
</head>

Macht das so Sinn?

Nicht so ganz.

Warum in einem style-Element und nicht im externen Stylesheet?

Weil der Pfad zum Font-File im njk-Template aus einer Variablen kommt.

Lato Light und font-weight: normal passt nicht so recht zusammen. Der Light-Schnitt ist font-weight: 300.

Hmmmm. Unter: http://www.latofonts.com/2014/02/27/lato-2-0-released/

... wird die Schrift auch mit font-weight: normal eingebunden. Ich habe das so verstanden, dass der Schnitt aus dem font kommt.

LLAP 🖖

gruss, heinetz