React - Inter Font Configuration

Sources:

  • **
title: Contents 
style: nestedList # TOC style (nestedList|inlineFirstLevel)
minLevel: 1 # Include headings from the specified level
maxLevel: 4 # Include headings up to the specified level
includeLinks: true # Make headings clickable
debugInConsole: false # Print debug info in Obsidian console

Overview

Configuring fonts for a React application can be done in many ways.

Code Snippet

Assumes usage of the FontSource library:

pnpm add @fontsource-variable/inter

Add import to project’s entry-point/root layout:

// src/index.tsx
import '@fontsource-variable/inter'; // Supports weights 100-900

Include CSS:

body {
  font-family: 'Inter Variable', sans-serif;
}

Details

About

This note is about …

See Also


Appendix

Note created on 2024-04-25 and last modified on 2024-04-25.

LIST FROM [[React - Inter Font Configuration]] AND -"CHANGELOG" AND -"04-RESOURCES/Code/React/React - Inter Font Configuration"

(c) No Clocks, LLC | 2024