Merge pull request #587 from lightpanda-io/dom-setchildnodes

cdp: dispatch DOM.setChildNodes event for search results
This commit is contained in:
Pierre Tachoire
2025-05-05 08:56:04 +02:00
committed by GitHub
6 changed files with 104 additions and 21 deletions

View File

@@ -99,7 +99,8 @@ pub const Element = struct {
}
pub fn get_attributes(self: *parser.Element) !*parser.NamedNodeMap {
return try parser.nodeGetAttributes(parser.elementToNode(self));
// An element must have non-nil attributes.
return try parser.nodeGetAttributes(parser.elementToNode(self)) orelse unreachable;
}
pub fn get_innerHTML(self: *parser.Element, state: *SessionState) ![]const u8 {