<div class='type'>Composable Function</div>


<a id='references'></a>

<div class='sourceset sourceset-android'>Android</div>


> **Deprecated** Prefer to preload fonts using FontFamily.Resolver.



<h2 id="fontresource-fontfamily">fontResource</h2>

```kotlin
@Composable
@ReadOnlyComposable
fun fontResource(fontFamily: FontFamily): Typeface
```


Synchronously load an font from `FontFamily`.

#### Parameters

| | |
| --- | --- |
| fontFamily | the fontFamily |


#### Returns

| | |
| --- | --- |
|  | the decoded image data associated with the resource |