We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f6d91ee commit 77ffeacCopy full SHA for 77ffeac
src/rules/form-control-has-label.ts
@@ -37,17 +37,19 @@ function hasNestedLabelElement(
37
return true;
38
}
39
40
- return (parent && parent.type === "VElement" && hasNestedLabelElement(parent, options));
+ return (
41
+ parent &&
42
+ parent.type === "VElement" &&
43
+ hasNestedLabelElement(parent, options)
44
+ );
45
46
47
/**
48
* Check if the form control at least has an "id" to be associated with a label
49
* Can't really check for the label with a matching "for" attribute, because
50
* checking every element in the file may lead to bad performance.
51
*/
-function hasIdForLabelElement(
- node: AST.VElement
-): boolean {
52
+function hasIdForLabelElement(node: AST.VElement): boolean {
53
const id = getElementAttributeValue(node, "id");
54
55
return Boolean(id);
0 commit comments