htmlToText function

String? htmlToText(
  1. String html, [
  2. NodeValidator? validator
])

Transform html to plain text.

Implementation

String? htmlToText(String html, [NodeValidator? validator]) {
  var elem = createHTML('<div>$html</div>', validator);
  return elem.text;
}