MCPcopy Index your code
hub / github.com/SeleniumHQ/selenium / getAttribute

Function getAttribute

javascript/atoms/typescript/get-attribute.ts:73–75  ·  view source on GitHub ↗
(element: Element, attributeName: string)

Source from the content-addressed store, hash-verified

71 ]);
72
73 function getAttribute(element: Element, attributeName: string): string | null {
74 return element.getAttribute(attributeName.toLowerCase());
75 }
76
77 function getProperty(element: Element, propertyName: string): unknown {
78 return (element as unknown as Record<string, unknown>)[propertyName];

Callers 1

get-attribute.tsFile · 0.85

Calls 1

getAttributeMethod · 0.65

Tested by

no test coverage detected