Skip to content

Instantly share code, notes, and snippets.

View mkbctrl's full-sized avatar

Mikołaj Koropecki mkbctrl

View GitHub Profile
@mkbctrl
mkbctrl / nextjs-fontfileobserver-example.tsx
Created April 4, 2020 19:28
[Next.js] [Typescript] Add internal ( self hosted ) font file with FontFaceObserver
// #### APP.TSX ####
// /src/pages/_app.tsx
import App from 'next/app'
import { loadFontPrimary } from '@utils/fontLoadObserver'
import FontFace from '@styles/FontFace'
import BaseStyles from '@styles/Base'
import { Reset } from 'styled-reset'
import VContainer from '@components/VContainer/VContainer'