--- name: preset-typography description: Prose classes for typographic defaults on vanilla HTML content --- # Preset Typography Prose classes for adding typographic defaults to vanilla HTML content. ## Installation ```ts import { defineConfig, presetTypography, presetWind3 } from 'unocss' export default defineConfig({ presets: [ presetWind3(), // Required! presetTypography(), ], }) ``` ## Basic Usage ```html

My Article

This is styled with typographic defaults...

``` ## Sizes ```html
Small
Base (default)
Large
Extra large
2X large
``` Responsive: ```html
Responsive typography
``` ## Colors ```html
Gray (default)
Slate
Blue
``` ## Dark Mode ```html
Dark mode typography
``` ## Excluding Elements ```html

Styled

NOT styled

``` **Note:** `not-prose` only works as a class. ## Options ```ts presetTypography({ selectorName: 'prose', // Custom selector cssVarPrefix: '--un-prose', // CSS variable prefix important: false, // Make !important cssExtend: { 'code': { color: '#8b5cf6' }, 'a:hover': { color: '#f43f5e' }, }, }) ```