feat: get all attributed that are !null

This commit is contained in:
karishmas6
2024-06-06 05:07:59 +05:30
parent 23a96b8118
commit f5af410064

View File

@@ -639,7 +639,14 @@ export const getSelectors = async (page: Page, coordinates: Coordinates) => {
return genAttributeSet(element, attributes).size > 0;
}
// Gets all attributes that aren't null and empty
function genValidAttributeFilter(element: HTMLElement, attributes: string[]) {
const attrSet = genAttributeSet(element, attributes);
return (name: string) => attrSet.has(name);
}
};