@agilebot/eslint-config 0.3.8 → 0.3.9

Sign up to get free protection for your applications and to get access to all the features.
package/LICENSE CHANGED
@@ -1,9 +1,9 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2024 Agilebot, Inc.
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
-
7
- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
-
9
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2024 Agilebot, Inc.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
+
7
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
+
9
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/LICENSE.tpl CHANGED
@@ -1,8 +1,8 @@
1
- /**
2
- * @license %(name)s v%(version)s
3
- *
4
- * Copyright (c) Agilebot, Inc. and its affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- */
1
+ /**
2
+ * @license %(name)s v%(version)s
3
+ *
4
+ * Copyright (c) Agilebot, Inc. and its affiliates.
5
+ *
6
+ * This source code is licensed under the MIT license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
package/README.md CHANGED
@@ -1,15 +1,15 @@
1
- # @agilebot/eslint-config
2
-
3
- ### Usage
4
-
5
- ```bash
6
- npm install --save-dev eslint \
7
- @agilebot/eslint-config
8
- ```
9
-
10
- ```js
11
- // .eslintrc.js
12
- const { agilebot } = require('@agilebot/eslint-config');
13
-
14
- module.exports = agilebot(__dirname);
15
- ```
1
+ # @agilebot/eslint-config
2
+
3
+ ### Usage
4
+
5
+ ```bash
6
+ npm install --save-dev eslint \
7
+ @agilebot/eslint-config
8
+ ```
9
+
10
+ ```js
11
+ // .eslintrc.js
12
+ const { agilebot } = require('@agilebot/eslint-config');
13
+
14
+ module.exports = agilebot(__dirname);
15
+ ```
@@ -1,2 +1,2 @@
1
- #!/usr/bin/env node
2
- require('../dist/cli').cli();
1
+ #!/usr/bin/env node
2
+ require('../dist/cli').cli();
package/dist/cli.js CHANGED
@@ -1,11 +1,11 @@
1
- /**
2
- * @license @agilebot/eslint-config v0.3.8
3
- *
4
- * Copyright (c) Agilebot, Inc. and its affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- */
1
+ /**
2
+ * @license @agilebot/eslint-config v0.3.9
3
+ *
4
+ * Copyright (c) Agilebot, Inc. and its affiliates.
5
+ *
6
+ * This source code is licensed under the MIT license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
9
 
10
10
  "use strict";
11
11
  var __create = Object.create;
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
- /**
2
- * @license @agilebot/eslint-config v0.3.8
3
- *
4
- * Copyright (c) Agilebot, Inc. and its affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- */
1
+ /**
2
+ * @license @agilebot/eslint-config v0.3.9
3
+ *
4
+ * Copyright (c) Agilebot, Inc. and its affiliates.
5
+ *
6
+ * This source code is licensed under the MIT license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
9
 
10
10
  "use strict";
11
11
  var __create = Object.create;
@@ -889,6 +889,7 @@ function react(opts) {
889
889
  "react-hooks/rules-of-hooks": "error",
890
890
  // recommended rules from @eslint-react/naming-convention
891
891
  "@eslint-react/naming-convention/component-name": "error",
892
+ "@eslint-react/naming-convention/use-state": "error",
892
893
  // 以下是自定义规则
893
894
  "react/jsx-handler-names": [
894
895
  "error",
@@ -898,15 +899,6 @@ function react(opts) {
898
899
  checkLocalVariables: true
899
900
  }
900
901
  ],
901
- // useState必须以[example, setExample]命名
902
- "react/hook-use-state": "error",
903
- // 组件命名符合帕斯卡
904
- "react/jsx-pascal-case": [
905
- "error",
906
- {
907
- allowNamespace: true
908
- }
909
- ],
910
902
  // 已经有ts校验,此规则没有必要,会与带静态属性的Functional Component冲突
911
903
  "react/prop-types": "off",
912
904
  // <App prop={'Hello'} />没必要,使用<App prop="Hello" />
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agilebot/eslint-config",
3
- "version": "0.3.8",
3
+ "version": "0.3.9",
4
4
  "description": "Agilebot's ESLint config",
5
5
  "bin": {
6
6
  "eslint-agilebot": "bin/eslint-agilebot"
@@ -44,14 +44,14 @@
44
44
  "eslint-plugin-vue": "^9.26.0",
45
45
  "eslint-plugin-you-dont-need-lodash-underscore": "^6.13.0",
46
46
  "vue-eslint-parser": "^9.4.2",
47
- "@agilebot/eslint-utils": "0.3.8"
47
+ "@agilebot/eslint-utils": "0.3.9"
48
48
  },
49
49
  "devDependencies": {
50
50
  "eslint-config-love": "^47.0.0"
51
51
  },
52
52
  "peerDependencies": {
53
53
  "eslint": "^7.0.0 || ^8.0.0",
54
- "@agilebot/eslint-plugin": "0.3.8"
54
+ "@agilebot/eslint-plugin": "0.3.9"
55
55
  },
56
56
  "files": [
57
57
  "bin",