Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
"VElement" (node) {
const nodeType = node.name
if (!typesToValidate.has(nodeType)) { return }
let DOMElement = nodeType
if (DOMElement === 'input') {
DOMElement = 'input[type="image"]'
}
if (elementOptions.indexOf(DOMElement) === -1) {
DOMElement = elementOptions.find((element) => {
const customComponentsForElement = options[element] || []
return customComponentsForElement.indexOf(nodeType) > -1
})
}
ruleByElement[DOMElement](context, node)
}
}, altRule.create(context))
}
}