html.utils

Classes


Public Protected Private

Global Functions

goog.html.utils.stripHtmlTags(value) string
Extracts text from HTML. Block-level elements such as div are surrounded with whitespace, but inline elements are not. Span is treated as a block level element because it is often used as a container. Breaking spaces are compressed and trimmed.
Arguments:
value : string
The input HTML to have tags removed.
Returns: string  A representation of value without tags, HTML comments, or other non-text content.
code »

Global Properties

goog.html.utils.HTML_TAG_REGEX_ :
Matches all tags, HTML comments, and DOCTYPEs in tag soup HTML. By removing these, and replacing any '<' or '>' characters with entities we guarantee that the result can be embedded into an attribute without introducing a tag boundary.
Code »
goog.html.utils.INLINE_HTML_TAG_REGEX_ :
Matches all tags that do not require extra space.
Code »

Package html

Package Reference