getOuterHtml function

String getOuterHtml(
  1. PageLoaderElement? element
)

Implementation

String getOuterHtml(PageLoaderElement? element) {
  if (element == null) {
    return 'null';
  }
  final elementString = element.properties['outerHTML']!;
  final bytes = utf8.encode(elementString);
  if (bytes.length > 50000) {
    return "(Length of Element's HTML DOM (${bytes.length}) is too "
        'long (>50 KB) to display)';
  }
  return elementString;
}