Iconseasy_svg_add_icon()

easy_svg_add_icon()

Stores one icon and returns only the state word.

Function · Easy SVG · Status: Internal · Defined in includes/icon-manager.php

Internal: not part of the promised public surface. It may change without notice.

Usage

easy_svg_add_icon( string $label, string $markup ): string

Example

$state = easy_svg_add_icon( 'Heart', $svg );

Description

A thin wrapper over easy_svg_add_icon_result(). It cannot tell you which slug the icon ended up with, so use the result function when that matters.

Parameters

body
$markupstring

Raw SVG markup.

Return value

returnstring

A state easy_svg_panel_add_message() has a sentence for.