WordPress at a glance
function is not described

Pelago\Emogrifier\HtmlProcessor

AbstractHtmlProcessor::fromHtml() public WC 1.0

Builds a new instance from the given HTML.

{} It's a method of the class: AbstractHtmlProcessor{}

No Hooks.

Return

static.

Usage

$result = AbstractHtmlProcessor::fromHtml( $unprocessedHtml );
$unprocessedHtml(string) (required)
raw HTML, must be UTF-encoded, must not be empty

Code of AbstractHtmlProcessor::fromHtml() WC 5.0.0

<?php
public static function fromHtml($unprocessedHtml)
{
    if (!\is_string($unprocessedHtml)) {
        throw new \InvalidArgumentException('The provided HTML must be a string.', 1515459744);
    }
    if ($unprocessedHtml === '') {
        throw new \InvalidArgumentException('The provided HTML must not be empty.', 1515763647);
    }

    $instance = new static();
    $instance->setHtml($unprocessedHtml);

    return $instance;
}