Skip to content

Function: createIcon()

ts
function createIcon(props?): Icon;

Defined in: packages/core/src/domain/Icon.ts:41

Create an Icon from partial properties.

Parameters

ParameterTypeDescription
propsIconIcon properties (all optional)

Returns

Icon

A frozen Icon instance

Example

typescript
const icon = createIcon({ src: '/icons/tool.svg', mimeType: 'image/svg+xml' });