mirror of
https://github.com/danbulant/oxc
synced 2026-05-22 05:38:54 +00:00
fix(linter): false positive in jsx-a11y/iframe-has-title (#7253)
closes #7243
This commit is contained in:
parent
44375a5662
commit
ef847dab9c
1 changed files with 4 additions and 0 deletions
|
|
@ -99,6 +99,9 @@ impl Rule for IframeHasTitle {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
JSXExpression::CallExpression(_) => {
|
||||||
|
return;
|
||||||
|
}
|
||||||
expr @ JSXExpression::Identifier(_) => {
|
expr @ JSXExpression::Identifier(_) => {
|
||||||
if !expr.is_undefined() {
|
if !expr.is_undefined() {
|
||||||
return;
|
return;
|
||||||
|
|
@ -124,6 +127,7 @@ fn test() {
|
||||||
(r"<iframe title='Unique title' />", None, None),
|
(r"<iframe title='Unique title' />", None, None),
|
||||||
(r"<iframe title={foo} />", None, None),
|
(r"<iframe title={foo} />", None, None),
|
||||||
(r"<FooComponent />", None, None),
|
(r"<FooComponent />", None, None),
|
||||||
|
(r"<iframe title={titleGenerator('hello')} />", None, None),
|
||||||
// CUSTOM ELEMENT TESTS FOR COMPONENTS SETTINGS
|
// CUSTOM ELEMENT TESTS FOR COMPONENTS SETTINGS
|
||||||
(
|
(
|
||||||
r"<FooComponent title='Unique title' />",
|
r"<FooComponent title='Unique title' />",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue