public function appendTextContent(string $content) : Tag
    {
        if ($this->isVoid) {
            throw new \LogicException('Void elements cannot have any contents.');
        }

        $this->content .= htmlspecialchars($content, ENT_NOQUOTES | ENT_HTML5);

        return $this;
    }
public function appendTextContent(string $content) : Tag
    {
        if ($this->isVoid) {
            throw new \LogicException('Void elements cannot have any contents.');
        }

        $this->content .= htmlspecialchars($content, ENT_NOQUOTES | ENT_HTML5);

        return $this;
    }
public function appendTextContent ( string $ content ) : Tag { if ( $ this -> isVoid ) { throw new \ LogicException ( 'Void elements cannot have any contents.' ) ; } $ this -> content .= htmlspecialchars ( $ content , ENT_NOQUOTES | ENT_HTML5 ) ; return $ this ; }
Appends text content to this tag.

@param string $content The text content.

@return Tag This instance, for chaining.

@throws \LogicException If this tag is a void element.
Appends text content to this tag .