fonts.FontWeight
A font file's weight: 'normal' (400), 'bold' (700), or 100 to 900 in hundreds.
Utilização
Register a downloaded font file with its weight.
// Register a downloaded font file with its weight.
import { fonts, type FontWeight } from 'kuito';
export async function registerHeadingFont(localFileURI: string) {
const weight: FontWeight = 700;
await fonts.load({ Heading: { uri: localFileURI, weight } });
}
// Pass a file:// URI, then use fontFamily="Heading" and fontWeight={700}.Declaração do tipo
export type FontWeight = 'normal' | 'bold' | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900;Tipo
"normal" | "bold" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900Gerado a partir das declarações TypeScript públicas: assinaturas, props e predefinições vêm da fonte verificada, as descrições da sua JSDoc. Nenhuma predefinição é inventada.