getOuterHTML method

Future<String> getOuterHTML({
  1. NodeId? nodeId,
  2. BackendNodeId? backendNodeId,
  3. RemoteObjectId? objectId,
})

Returns node's HTML markup. nodeId Identifier of the node. backendNodeId Identifier of the backend node. objectId JavaScript object id of the node wrapper. Returns: Outer HTML markup.

Implementation

Future<String> getOuterHTML(
    {NodeId? nodeId,
    BackendNodeId? backendNodeId,
    runtime.RemoteObjectId? objectId}) async {
  var result = await _client.send('DOM.getOuterHTML', {
    if (nodeId != null) 'nodeId': nodeId,
    if (backendNodeId != null) 'backendNodeId': backendNodeId,
    if (objectId != null) 'objectId': objectId,
  });
  return result['outerHTML'] as String;
}