---
url: /api/renderers/tinymce/src/functions/getIconImageSrc.md
---
[pantoken-root](../../../../index.md) / [renderers/tinymce/src](../index.md) / getIconImageSrc

# Function: getIconImageSrc()

> **getIconImageSrc**(`icon`, `root?`): `string` | `undefined`

A `data:` URI usable as an `<img src>` for the icon, for sources this package bundles; for the
rest it reads the custom property back off `root`, which resolves once the source's glyph sheet
has loaded. Returns `undefined` when neither path yields a glyph.

## Parameters

### icon

[`TaggedIcon`](../interfaces/TaggedIcon.md)

### root?

`Element`

## Returns

`string` | `undefined`
