We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 55ded2e commit ae84151Copy full SHA for ae84151
lib/rules/autocomplete-a11y-matches.js
@@ -81,17 +81,15 @@ function quantityField(node) {
81
'data-placeholder',
82
'role'
83
];
84
- for (const attr of attributes) {
+ return attributes.some(attr => {
85
if (node.hasAttribute(attr)) {
86
const value = node.getAttribute(attr).toLowerCase();
87
- for (const keyword of keywords) {
88
- if (value && value.includes(keyword.toLowerCase())) {
89
- return true;
90
- }
91
+ return keywords.some(
+ keyword => value && value.includes(keyword.toLowerCase())
+ );
92
}
93
94
- return false;
+ return false;
+ });
95
96
97
function autocompleteA11yMatches(node, virtualNode) {
0 commit comments