toSvgString

fun toSvgString(customisations: IconifyIconCustomisations? = definedExternally, prettyPrint: Boolean = definedExternally): String

Get the SVG as a string.

With customisations, builds a new SVG via iconToSVG, including the needed namespaces and attributes. Without customisations, keeps the original document and adds a missing viewBox, width or height. prettyPrint controls whitespace in the output.