@inkdes-email/font
v0.3.1
Published
A React email font component to to style your email (InkDes Mailer)
Maintainers
Readme
@inkdes-email/font
Font component used inside tag.
Installation
# pnpm
pnpm add @inkdes-email/font
# npm
npm install @inkdes-email/font
# yarn
yarn add @inkdes-email/fontQuick start
import { Font } from "@inkdes-email/font";
export default function EmailTemplate() {
return <Font
family='Inter'
url='https://fonts.gstatic.com/s/inter/v20/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhiJ-Ek-_EeAmM.woff2'
type='woff2'
fallback='Arial'
style='normal'
weight='400'
targetSelectors={['body', '.class1']}
/>
}Props
| Name | Type | Required | Default | Description | | -------- | ---------------------- | -------- | ------- | ----------------------------------- | | children | React.ReactNode | Yes | — | Content of the email document | | family | String | Yes | — | - | | url | String | Yes | — | - | | type | String | Yes | — | "woff2" or "woff" | | style | String | Yes | — | - | | weigth | String | Yes | — | 400 | | targetSelectors | Array of css selector strings | No | — | |
All other standard Head attributes for the <head> element are supported.
License
MIT © iClasser
