@lobehub/lint 1.15.2 → 1.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -179,7 +179,7 @@ $ npm start
179
179
 
180
180
  <!-- CONTRIBUTION GROUP -->
181
181
 
182
- > 📊 Total: <kbd>**2**</kbd>
182
+ > 📊 Total: <kbd>**4**</kbd>
183
183
 
184
184
  <a href="https://github.com/canisminor1990" title="canisminor1990">
185
185
  <img src="https://avatars.githubusercontent.com/u/17870709?v=4" width="50" />
@@ -187,6 +187,12 @@ $ npm start
187
187
  <a href="https://github.com/actions-user" title="actions-user">
188
188
  <img src="https://avatars.githubusercontent.com/u/65916846?v=4" width="50" />
189
189
  </a>
190
+ <a href="https://github.com/arvinxx" title="arvinxx">
191
+ <img src="https://avatars.githubusercontent.com/u/28616219?v=4" width="50" />
192
+ </a>
193
+ <a href="https://github.com/apps/dependabot" title="dependabot[bot]">
194
+ <img src="https://avatars.githubusercontent.com/in/29110?v=4" width="50" />
195
+ </a>
190
196
 
191
197
  <!-- CONTRIBUTION END -->
192
198
 
@@ -200,58 +206,28 @@ $ npm start
200
206
 
201
207
  #### 📝 License
202
208
 
203
- Copyright © 2023 ~ present [LobeHub][profile-url]. <br />
209
+ Copyright © 2023 \~ present [LobeHub][profile-url]. <br />
204
210
  This project is [MIT](./LICENSE) licensed.
205
211
 
206
212
  <!-- LINK GROUP -->
207
213
 
208
- [profile-url]: https://github.com/lobehub
209
- [gitpod-url]: https://gitpod.io/#https://github.com/lobehub/lobe-lint
210
-
211
- <!-- SHIELD LINK GROUP -->
212
-
213
214
  [back-to-top]: https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square
214
-
215
- <!-- release -->
216
-
217
- [release-shield]: https://img.shields.io/npm/v/@lobehub/lint?label=%F0%9F%A4%AF%20NPM
218
- [release-url]: https://www.npmjs.com/package/@lobehub/lint
219
-
220
- <!-- releaseDate -->
221
-
222
- [release-date-shield]: https://img.shields.io/github/release-date/lobehub/lobe-lint?style=flat
223
- [release-date-url]: https://github.com/lobehub/lobe-lint/releases
224
-
225
- <!-- releaseDownload -->
226
-
227
- [release-download-shield]: https://img.shields.io/npm/dt/@lobehub/lint
228
-
229
- <!-- ciTest -->
230
-
231
- [ci-test-shield]: https://github.com/lobehub/lobe-lint/workflows/Test%20CI/badge.svg
232
- [ci-test-url]: https://github.com/lobehub/lobe-lint/actions/workflows/test.yml
233
-
234
- <!-- ciRelease -->
235
-
236
215
  [ci-release-shield]: https://github.com/lobehub/lobe-lint/workflows/Build%20and%20Release/badge.svg
237
216
  [ci-release-url]: https://github.com/lobehub/lobe-lint/actions/workflows/release.yml
238
-
239
- <!-- contributors -->
240
-
217
+ [ci-test-shield]: https://github.com/lobehub/lobe-lint/workflows/Test%20CI/badge.svg
218
+ [ci-test-url]: https://github.com/lobehub/lobe-lint/actions/workflows/test.yml
241
219
  [contributors-shield]: https://img.shields.io/github/contributors/lobehub/lobe-lint.svg?style=flat
242
220
  [contributors-url]: https://github.com/lobehub/lobe-lint/graphs/contributors
243
-
244
- <!-- forks -->
245
-
246
221
  [forks-shield]: https://img.shields.io/github/forks/lobehub/lobe-lint.svg?style=flat
247
222
  [forks-url]: https://github.com/lobehub/lobe-lint/network/members
248
-
249
- <!-- stargazers -->
250
-
251
- [stargazers-shield]: https://img.shields.io/github/stars/lobehub/lobe-lint.svg?style=flat
252
- [stargazers-url]: https://github.com/lobehub/lobe-lint/stargazers
253
-
254
- <!-- issues -->
255
-
223
+ [gitpod-url]: https://gitpod.io/#https://github.com/lobehub/lobe-lint
256
224
  [issues-shield]: https://img.shields.io/github/issues/lobehub/lobe-lint.svg?style=flat
257
225
  [issues-url]: https://github.com/lobehub/lobe-lint/issues/new/choose
226
+ [profile-url]: https://github.com/lobehub
227
+ [release-date-shield]: https://img.shields.io/github/release-date/lobehub/lobe-lint?style=flat
228
+ [release-date-url]: https://github.com/lobehub/lobe-lint/releases
229
+ [release-download-shield]: https://img.shields.io/npm/dt/@lobehub/lint
230
+ [release-shield]: https://img.shields.io/npm/v/@lobehub/lint?label=%F0%9F%A4%AF%20NPM
231
+ [release-url]: https://www.npmjs.com/package/@lobehub/lint
232
+ [stargazers-shield]: https://img.shields.io/github/stars/lobehub/lobe-lint.svg?style=flat
233
+ [stargazers-url]: https://github.com/lobehub/lobe-lint/stargazers
@@ -1,68 +1,6 @@
1
1
  declare const _default: {
2
2
  $schema: string;
3
- env: {
4
- browser: boolean;
5
- es2022: boolean;
6
- jest: boolean;
7
- node: boolean;
8
- };
9
3
  extends: string[];
10
- overrides: ({
11
- files: string[];
12
- parser: string;
13
- plugins: string[];
14
- rules: {
15
- '@typescript-eslint/ban-types': number;
16
- '@typescript-eslint/no-confusing-non-null-assertion': number;
17
- '@typescript-eslint/no-dupe-class-members': number;
18
- '@typescript-eslint/no-empty-interface': number;
19
- '@typescript-eslint/no-invalid-this': number;
20
- '@typescript-eslint/no-loop-func': number;
21
- '@typescript-eslint/no-misused-new': number;
22
- '@typescript-eslint/no-namespace': number;
23
- '@typescript-eslint/no-non-null-asserted-optional-chain': number;
24
- '@typescript-eslint/no-redeclare': number;
25
- '@typescript-eslint/no-this-alias': number;
26
- '@typescript-eslint/no-unused-expressions': number;
27
- '@typescript-eslint/no-unused-vars': number;
28
- '@typescript-eslint/no-use-before-define': number;
29
- '@typescript-eslint/no-useless-constructor': number;
30
- '@typescript-eslint/triple-slash-reference': number;
31
- };
32
- } | {
33
- files: string[];
34
- plugins: string[];
35
- rules: {
36
- 'jest/no-conditional-expect': number;
37
- 'jest/no-deprecated-functions': number;
38
- 'jest/no-export': number;
39
- 'jest/no-focused-tests': number;
40
- 'jest/no-identical-title': number;
41
- 'jest/no-interpolation-in-snapshots': number;
42
- 'jest/no-jasmine-globals': number;
43
- 'jest/no-mocks-import': number;
44
- 'jest/no-standalone-expect': number;
45
- 'jest/valid-describe-callback': number;
46
- 'jest/valid-expect-in-promise': number;
47
- 'jest/valid-expect': number;
48
- 'jest/valid-title': number;
49
- };
50
- parser?: undefined;
51
- })[];
52
- parser: string;
53
- parserOptions: {
54
- babelOptions: {
55
- babelrc: boolean;
56
- browserslistConfigFile: boolean;
57
- configFile: boolean;
58
- presets: string[];
59
- };
60
- ecmaFeatures: {
61
- jsx: boolean;
62
- };
63
- requireConfigFile: boolean;
64
- tsconfigRootDir: string;
65
- };
66
4
  plugins: string[];
67
5
  rules: {
68
6
  '@typescript-eslint/ban-ts-comment': number;
@@ -107,60 +45,6 @@ declare const _default: {
107
45
  vars: string;
108
46
  varsIgnorePattern: string;
109
47
  })[];
110
- 'array-callback-return': number;
111
- eqeqeq: number;
112
- 'for-direction': number;
113
- 'guard-for-in': number;
114
- 'no-async-promise-executor': number;
115
- 'no-case-declarations': number;
116
- 'no-debugger': number;
117
- 'no-delete-var': number;
118
- 'no-dupe-else-if': number;
119
- 'no-duplicate-case': number;
120
- 'no-eval': number;
121
- 'no-ex-assign': number;
122
- 'no-global-assign': number;
123
- 'no-invalid-regexp': number;
124
- 'no-native-reassign': number;
125
- 'no-param-reassign': number;
126
- 'no-promise-executor-return': number;
127
- 'no-self-assign': number;
128
- 'no-self-compare': number;
129
- 'no-shadow-restricted-names': number;
130
- 'no-sparse-arrays': number;
131
- 'no-unsafe-finally': number;
132
- 'no-unused-labels': number;
133
- 'no-useless-catch': number;
134
- 'no-useless-escape': number;
135
- 'no-var': number;
136
- 'no-with': number;
137
- 'require-yield': number;
138
- 'use-isnan': number;
139
- 'react/button-has-type': number;
140
- 'react/jsx-key': number;
141
- 'react/jsx-no-comment-textnodes': number;
142
- 'react/jsx-no-duplicate-props': number;
143
- 'react/jsx-no-target-blank': number;
144
- 'react/jsx-no-undef': number;
145
- 'react/jsx-uses-react': number;
146
- 'react/jsx-uses-vars': number;
147
- 'react/no-children-prop': number;
148
- 'react/no-danger-with-children': number;
149
- 'react/no-deprecated': number;
150
- 'react/no-direct-mutation-state': number;
151
- 'react/no-find-dom-node': number;
152
- 'react/no-is-mounted': number;
153
- 'react/no-string-refs': number;
154
- 'react/no-render-return-value': number;
155
- 'react/no-unescaped-entities': number;
156
- 'react/no-unknown-property': number;
157
- 'react/require-render-return': number;
158
- 'react-hooks/rules-of-hooks': number;
159
- };
160
- settings: {
161
- react: {
162
- version: string;
163
- };
164
48
  };
165
49
  };
166
50
  export default _default;
@@ -32,60 +32,22 @@ __export(eslint_exports, {
32
32
  default: () => eslint_default
33
33
  });
34
34
  module.exports = __toCommonJS(eslint_exports);
35
- var import_recommended = __toESM(require("@umijs/lint/dist/config/eslint/rules/recommended"));
36
35
  var eslint_default = {
37
36
  $schema: "https://json.schemastore.org/eslintrc",
38
- env: {
39
- browser: true,
40
- es2022: true,
41
- jest: true,
42
- node: true
43
- },
44
37
  extends: [
45
- "prettier",
46
38
  "eslint:recommended",
47
- "plugin:react/recommended",
39
+ require.resolve("@umijs/lint/dist/config/eslint"),
48
40
  "plugin:unicorn/recommended"
49
41
  ],
50
- overrides: [
51
- {
52
- files: ["**/*.{ts,tsx}"],
53
- parser: require.resolve("@typescript-eslint/parser"),
54
- plugins: ["@typescript-eslint/eslint-plugin"],
55
- rules: import_recommended.typescript
56
- },
57
- {
58
- files: ["**/*.{test,spec,unit,e2e}.{ts,tsx,js,jsx}"],
59
- plugins: ["jest"],
60
- rules: import_recommended.jest
61
- }
62
- ],
63
- parser: require.resolve("@babel/eslint-parser"),
64
- parserOptions: {
65
- babelOptions: {
66
- babelrc: false,
67
- browserslistConfigFile: false,
68
- configFile: false,
69
- presets: [require.resolve("@umijs/babel-preset-umi")]
70
- },
71
- ecmaFeatures: {
72
- jsx: true
73
- },
74
- requireConfigFile: false,
75
- tsconfigRootDir: __dirname
76
- },
77
42
  plugins: [
78
43
  "unicorn",
79
44
  "import",
80
45
  "unused-imports",
81
46
  "simple-import-sort",
82
47
  "sort-keys-fix",
83
- "typescript-sort-keys",
84
- "react",
85
- "react-hooks"
48
+ "typescript-sort-keys"
86
49
  ],
87
50
  rules: {
88
- ...import_recommended.default,
89
51
  "@typescript-eslint/ban-ts-comment": 0,
90
52
  "@typescript-eslint/no-explicit-any": 0,
91
53
  "import/first": "error",
@@ -126,10 +88,5 @@ var eslint_default = {
126
88
  "warn",
127
89
  { args: "after-used", argsIgnorePattern: "^_", vars: "all", varsIgnorePattern: "^_" }
128
90
  ]
129
- },
130
- settings: {
131
- react: {
132
- version: "detect"
133
- }
134
91
  }
135
92
  };
@@ -27,6 +27,10 @@ var remarklint_default = {
27
27
  plugins: [
28
28
  "remark-gfm",
29
29
  "remark-frontmatter",
30
+ // ----- Plugin -----------------------------------------------------------
31
+ "remark-sort-definitions",
32
+ ["remark-toc", { heading: "TOC", maxDepth: 3 }],
33
+ "remark-remove-unused-definitions",
30
34
  // ----- Presets -----------------------------------------------------------
31
35
  "remark-preset-lint-markdown-style-guide",
32
36
  "remark-preset-lint-recommended",
@@ -47,7 +51,6 @@ var remarklint_default = {
47
51
  "remark-lint-no-empty-sections",
48
52
  "remark-lint-write-good",
49
53
  "remark-lint-frontmatter-schema",
50
- ["remark-toc", { heading: "TOC", maxDepth: 3 }],
51
54
  // ----- Overrides ---------------------------------------------------------
52
55
  ["remark-lint-list-item-indent", "space"],
53
56
  ["remark-lint-list-item-spacing", { checkBlanks: true }],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/lint",
3
- "version": "1.15.2",
3
+ "version": "1.17.0",
4
4
  "homepage": "https://github.com/lobehub/lobe-lint",
5
5
  "bugs": {
6
6
  "url": "https://github.com/lobehub/lobe-lint/issues/new"
@@ -68,6 +68,8 @@
68
68
  "remark-preset-lint-consistent": "latest",
69
69
  "remark-preset-lint-markdown-style-guide": "latest",
70
70
  "remark-preset-lint-recommended": "latest",
71
+ "remark-remove-unused-definitions": "latest",
72
+ "remark-sort-definitions": "latest",
71
73
  "remark-toc": "latest",
72
74
  "semantic-release-config-gitmoji": "latest",
73
75
  "stylelint-config-clean-order": "latest",