This repository was archived by the owner on Jan 2, 2025. It is now read-only.
File tree 2 files changed +8
-7
lines changed
2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -41,10 +41,10 @@ module.exports = {
41
41
"error" ,
42
42
{
43
43
cases : {
44
- kebabCase : true , // 是否支持横杠 (-) 命名
45
- camelCase : false , // 是否支持小驼峰命名
46
- snakeCase : false , // 是否支持 (_) 下划线命名
47
- pascalCase : false , // 是否支持大坨峰命名
44
+ kebabCase : true , // 支持横杠 (-) 命名
45
+ camelCase : false , // 支持小驼峰命名
46
+ snakeCase : false , // 支持 (_) 下划线命名
47
+ pascalCase : false , // 支持大坨峰命名
48
48
} ,
49
49
} ,
50
50
] ,
@@ -61,9 +61,10 @@ module.exports = {
61
61
next : "*" ,
62
62
} ,
63
63
] ,
64
- "@typescript-eslint/no-var-requires" : 0 , // 关闭禁止使用 require 语句
64
+ "@typescript-eslint/no-var-requires" : 0 , // (关闭) 禁止使用 require 语句
65
65
"@sj-distributor/react/interface-name-prefix" : [ "error" , "I" ] , // 默认强制 interface 大写 I 前缀
66
- "react/display-name" : 0 , // 关闭(不允许在 React 组件定义中缺少 displayName)
66
+ "react/display-name" : 0 , // (关闭) 不允许在 React 组件定义中缺少 displayName
67
+ "react/self-closing-comp" : 2 , // 检测 JSX 中的所有组件和 HTML 元素,如果元素没有子元素,就会自动转换为自闭合形式
67
68
} ,
68
69
// 共享配置,提供给每一个将被执行的规则
69
70
settings : {
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @sj-distributor/eslint-plugin-react" ,
3
- "version" : " 0.7.0 " ,
3
+ "version" : " 0.7.1 " ,
4
4
"description" : " ESLint presets for react" ,
5
5
"keywords" : [
6
6
" eslint" ,
You can’t perform that action at this time.
0 commit comments