ソースを参照

feat: 加入标签自闭合规则

lanjianrong 4 年 前
コミット
1d3d2b8980
1 ファイル変更5 行追加1 行削除
  1. 5 1
      .eslintrc

+ 5 - 1
.eslintrc

@@ -24,7 +24,11 @@
     "react/prop-types": 0,
     "array-bracket-spacing": ["error", "always"],
     "object-curly-spacing": ["error", "always"],
-    "react-hooks/rules-of-hooks": "error"
+    "react-hooks/rules-of-hooks": "error",
+    "react/self-closing-comp": ["error", {
+      "component": true,
+      "html": true
+    }]
     // "react-hooks/exhaustive-deps": "warn"
   },
   "settings": {