@lobehub/lint 1.1.1 → 1.2.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 +11 -5
- package/dist/eslint/index.js +8 -2
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -13,6 +13,7 @@ ESlint config, Prettier config, Remark config for LobeHub
|
|
|
13
13
|
<!-- SHIELD GROUP -->
|
|
14
14
|
|
|
15
15
|
[![release][release-shield]][release-url]
|
|
16
|
+
![][release-download-shield]
|
|
16
17
|
[![releaseDate][release-date-shield]][release-date-url]
|
|
17
18
|
[![ciTest][ci-test-shield]][ci-test-url]
|
|
18
19
|
[![ciRelease][ci-release-shield]][ci-release-url] <br/>
|
|
@@ -79,13 +80,14 @@ curl -O https://raw.githubusercontent.com/lobehub/lobe-lint/master/.prettierigno
|
|
|
79
80
|
|
|
80
81
|
```text
|
|
81
82
|
public-hoist-pattern[]=*@umijs/lint*
|
|
82
|
-
public-hoist-pattern[]=*
|
|
83
|
-
public-hoist-pattern[]=*eslint*
|
|
84
|
-
public-hoist-pattern[]=*stylelint*
|
|
85
|
-
public-hoist-pattern[]=*prettier*
|
|
83
|
+
public-hoist-pattern[]=*changelog*
|
|
86
84
|
public-hoist-pattern[]=*commitlint*
|
|
85
|
+
public-hoist-pattern[]=*eslint*
|
|
87
86
|
public-hoist-pattern[]=*postcss*
|
|
87
|
+
public-hoist-pattern[]=*prettier*
|
|
88
|
+
public-hoist-pattern[]=*remark*
|
|
88
89
|
public-hoist-pattern[]=*semantic-release*
|
|
90
|
+
public-hoist-pattern[]=*stylelint*
|
|
89
91
|
```
|
|
90
92
|
|
|
91
93
|
### ESlint
|
|
@@ -125,7 +127,7 @@ config can be found at `./src/changelog/index.ts`
|
|
|
125
127
|
```js
|
|
126
128
|
// .changelogrc.js
|
|
127
129
|
|
|
128
|
-
module.exports = require('@lobehub/lint/dist/
|
|
130
|
+
module.exports = require('@lobehub/lint/dist/changelog');
|
|
129
131
|
```
|
|
130
132
|
|
|
131
133
|
### Remark
|
|
@@ -232,6 +234,10 @@ This project is [MIT](./LICENSE) licensed.
|
|
|
232
234
|
[release-date-shield]: https://img.shields.io/github/release-date/lobehub/lobe-lint?style=flat
|
|
233
235
|
[release-date-url]: https://github.com/lobehub/lobe-lint/releases
|
|
234
236
|
|
|
237
|
+
<!-- releaseDownload -->
|
|
238
|
+
|
|
239
|
+
[release-download-shield]: https://img.shields.io/npm/dt/@lobehub/lint
|
|
240
|
+
|
|
235
241
|
<!-- ciTest -->
|
|
236
242
|
|
|
237
243
|
[ci-test-shield]: https://github.com/lobehub/lobe-lint/workflows/Test%20CI/badge.svg
|
package/dist/eslint/index.js
CHANGED
|
@@ -24,7 +24,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
24
24
|
// src/eslint/index.ts
|
|
25
25
|
module.exports = {
|
|
26
26
|
extends: [require.resolve("@umijs/lint/dist/config/eslint")],
|
|
27
|
-
plugins: ["simple-import-sort", "import", "typescript-sort-keys"],
|
|
27
|
+
plugins: ["simple-import-sort", "import", "typescript-sort-keys", "unused-imports"],
|
|
28
28
|
rules: {
|
|
29
29
|
"simple-import-sort/exports": "error",
|
|
30
30
|
"import/first": "error",
|
|
@@ -33,6 +33,12 @@ module.exports = {
|
|
|
33
33
|
"typescript-sort-keys/interface": "error",
|
|
34
34
|
"typescript-sort-keys/string-enum": "error",
|
|
35
35
|
"react/jsx-sort-props": "error",
|
|
36
|
-
"react/jsx-no-useless-fragment": "error"
|
|
36
|
+
"react/jsx-no-useless-fragment": "error",
|
|
37
|
+
"no-unused-vars": "off",
|
|
38
|
+
"unused-imports/no-unused-imports": "error",
|
|
39
|
+
"unused-imports/no-unused-vars": [
|
|
40
|
+
"warn",
|
|
41
|
+
{ vars: "all", varsIgnorePattern: "^_", args: "after-used", argsIgnorePattern: "^_" }
|
|
42
|
+
]
|
|
37
43
|
}
|
|
38
44
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/lint",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"homepage": "https://github.com/lobehub/lobe-lint",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"url": "https://github.com/lobehub/lobe-lint/issues/new"
|
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
"eslint-plugin-import": "latest",
|
|
28
28
|
"eslint-plugin-simple-import-sort": "latest",
|
|
29
29
|
"eslint-plugin-typescript-sort-keys": "latest",
|
|
30
|
+
"eslint-plugin-unused-imports": "latest",
|
|
30
31
|
"postcss-less": "latest",
|
|
31
32
|
"postcss-styled-syntax": "latest",
|
|
32
33
|
"prettier-plugin-organize-imports": "latest",
|