diff --git a/lib/rules/no-invalid-html-attribute.js b/lib/rules/no-invalid-html-attribute.js
index e82c4c4316..cdba56a66d 100644
--- a/lib/rules/no-invalid-html-attribute.js
+++ b/lib/rules/no-invalid-html-attribute.js
@@ -306,9 +306,12 @@ function checkLiteralValueNode(context, attributeName, node, parentNode, parentN
if (allowedPairsForAttribute) {
const pairAttributeParts = splitIntoRangedParts(node, /(?=(\b\S+\s*\S+))/g);
for (const pairPart of pairAttributeParts) {
- for (const [pairing, siblings] of allowedPairsForAttribute) {
+ for (const allowedPair of allowedPairsForAttribute) {
+ const pairing = allowedPair[0];
+ const siblings = allowedPair[1];
const attributes = pairPart.reportingValue.split('\u0020');
- const [firstValue, secondValue] = attributes;
+ const firstValue = attributes[0];
+ const secondValue = attributes[1];
if (firstValue === pairing) {
const lastValue = attributes[attributes.length - 1]; // in case of multiple white spaces
if (!siblings.has(lastValue)) {
@@ -319,7 +322,7 @@ function checkLiteralValueNode(context, attributeName, node, parentNode, parentN
data: {
reportingValue: firstValue,
secondValue,
- missingValue: [...siblings].join(', '),
+ missingValue: Array.from(siblings).join(', '),
},
});
}