Skip to content

no-nested-interactive

Detect interactive content inside a or button.

Severity

error

❌ Incorrect

html
<a href="#">
  <button>x</button>
</a>

✅ Correct

html
<a href="#">text</a>

Reference

Configuration

json
{
  "rules": {
    "no-nested-interactive": "error"
  }
}

Released under the MIT License.