Automattic\WooCommerce\EmailEditor\Engine\Renderer
Html2Text::is_whitespace
Check if text is whitespace
Method of the class: Html2Text{}
No Hooks.
Returns
true|false. True if the text is whitespace.
Usage
$result = Html2Text::is_whitespace( $text ): bool;
- $text(string) (required)
- The text to check.
Html2Text::is_whitespace() Html2Text::is whitespace code WC 10.5.0
public static function is_whitespace( string $text ): bool {
return 0 === strlen( trim( self::render_text( $text ), "\n\r\t " ) );
}