📌  相关文章
📜  表单标签必须与控件相关联. - 无论代码示例

📅  最后修改于: 2022-03-11 14:58:18.790000             🧑  作者: Mango

代码示例1
{
    ....
    "rules": {
      "jsx-a11y/label-has-associated-control": ["error", {
        "required": {
          "some": ["nesting", "id"]
        }
      }],
      "jsx-a11y/label-has-for": ["error", {
        "required": {
          "some": ["nesting", "id"]
        }
      }]
    },
    ...
}