@lobehub/lint 1.5.0 → 1.6.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.
@@ -1,22 +1,22 @@
1
1
  declare const _default: {
2
- displayTypes: string[];
3
- newlineTimestamp: boolean;
4
- reduceHeadingLevel: boolean;
5
2
  addBackToTop: boolean;
6
- showSummary: boolean;
7
- scopeDisplayName: {
8
- '*': string;
9
- };
10
3
  customTypeMap: {
11
4
  build: {
12
- emojj: string;
5
+ emoji: string;
13
6
  };
14
7
  chore: {
15
- emojj: string;
8
+ emoji: string;
16
9
  };
17
10
  ci: {
18
- emojj: string;
11
+ emoji: string;
19
12
  };
20
13
  };
14
+ displayTypes: string[];
15
+ newlineTimestamp: boolean;
16
+ reduceHeadingLevel: boolean;
17
+ scopeDisplayName: {
18
+ '*': string;
19
+ };
20
+ showSummary: boolean;
21
21
  };
22
22
  export default _default;
@@ -23,23 +23,23 @@ __export(changelog_exports, {
23
23
  });
24
24
  module.exports = __toCommonJS(changelog_exports);
25
25
  var changelog_default = {
26
- displayTypes: ["feat", "fix", "styles", "pref", "refactor"],
27
- newlineTimestamp: true,
28
- reduceHeadingLevel: true,
29
26
  addBackToTop: true,
30
- showSummary: true,
31
- scopeDisplayName: {
32
- "*": "misc"
33
- },
34
27
  customTypeMap: {
35
28
  build: {
36
- emojj: "📦"
29
+ emoji: "📦"
37
30
  },
38
31
  chore: {
39
- emojj: "🔧"
32
+ emoji: "🔧"
40
33
  },
41
34
  ci: {
42
- emojj: "👷"
35
+ emoji: "👷"
43
36
  }
44
- }
37
+ },
38
+ displayTypes: ["feat", "fix", "style", "pref", "refactor"],
39
+ newlineTimestamp: true,
40
+ reduceHeadingLevel: true,
41
+ scopeDisplayName: {
42
+ "*": "misc"
43
+ },
44
+ showSummary: true
45
45
  };
@@ -2,21 +2,23 @@ declare const _default: {
2
2
  extends: string[];
3
3
  plugins: string[];
4
4
  rules: {
5
- 'simple-import-sort/exports': string;
6
5
  'import/first': string;
7
6
  'import/newline-after-import': string;
8
7
  'import/no-duplicates': string;
8
+ 'no-unused-vars': string;
9
+ 'react/jsx-no-useless-fragment': string;
10
+ 'react/jsx-sort-props': string;
11
+ 'simple-import-sort/exports': string;
12
+ 'sort-keys-fix/sort-keys-fix': string;
9
13
  'typescript-sort-keys/interface': string;
10
14
  'typescript-sort-keys/string-enum': string;
11
- 'react/jsx-sort-props': string;
12
- 'react/jsx-no-useless-fragment': string;
13
- 'no-unused-vars': string;
15
+ 'unicorn/prefer-module': string;
14
16
  'unused-imports/no-unused-imports': string;
15
17
  'unused-imports/no-unused-vars': (string | {
16
- vars: string;
17
- varsIgnorePattern: string;
18
18
  args: string;
19
19
  argsIgnorePattern: string;
20
+ vars: string;
21
+ varsIgnorePattern: string;
20
22
  })[];
21
23
  };
22
24
  };
@@ -33,22 +33,31 @@ __export(eslint_exports, {
33
33
  });
34
34
  module.exports = __toCommonJS(eslint_exports);
35
35
  var eslint_default = {
36
- extends: [require.resolve("@umijs/lint/dist/config/eslint")],
37
- plugins: ["simple-import-sort", "import", "typescript-sort-keys", "unused-imports"],
36
+ extends: [require.resolve("@umijs/lint/dist/config/eslint"), "plugin:unicorn/recommended"],
37
+ plugins: [
38
+ "unicorn",
39
+ "import",
40
+ "unused-imports",
41
+ "simple-import-sort",
42
+ "sort-keys-fix",
43
+ "typescript-sort-keys"
44
+ ],
38
45
  rules: {
39
- "simple-import-sort/exports": "error",
40
46
  "import/first": "error",
41
47
  "import/newline-after-import": "error",
42
48
  "import/no-duplicates": "error",
43
- "typescript-sort-keys/interface": "error",
44
- "typescript-sort-keys/string-enum": "error",
45
- "react/jsx-sort-props": "error",
46
- "react/jsx-no-useless-fragment": "error",
47
49
  "no-unused-vars": "off",
50
+ "react/jsx-no-useless-fragment": "error",
51
+ "react/jsx-sort-props": "error",
52
+ "simple-import-sort/exports": "error",
53
+ "sort-keys-fix/sort-keys-fix": "warn",
54
+ "typescript-sort-keys/interface": "warn",
55
+ "typescript-sort-keys/string-enum": "warn",
56
+ "unicorn/prefer-module": "warn",
48
57
  "unused-imports/no-unused-imports": "error",
49
58
  "unused-imports/no-unused-vars": [
50
59
  "warn",
51
- { vars: "all", varsIgnorePattern: "^_", args: "after-used", argsIgnorePattern: "^_" }
60
+ { args: "after-used", argsIgnorePattern: "^_", vars: "all", varsIgnorePattern: "^_" }
52
61
  ]
53
62
  }
54
63
  };
@@ -1,17 +1,17 @@
1
1
  declare const _default: {
2
- plugins: string[];
3
- printWidth: number;
4
- proseWrap: string;
5
- singleQuote: boolean;
6
- trailingComma: string;
2
+ importOrder: string[];
7
3
  importOrderSeparation: boolean;
8
4
  importOrderSortSpecifiers: boolean;
9
- importOrder: string[];
10
5
  overrides: {
11
6
  files: string;
12
7
  options: {
13
8
  proseWrap: string;
14
9
  };
15
10
  }[];
11
+ plugins: string[];
12
+ printWidth: number;
13
+ proseWrap: string;
14
+ singleQuote: boolean;
15
+ trailingComma: string;
16
16
  };
17
17
  export default _default;
@@ -33,19 +33,9 @@ __export(prettier_exports, {
33
33
  });
34
34
  module.exports = __toCommonJS(prettier_exports);
35
35
  var prettier_default = {
36
- plugins: [
37
- require.resolve("prettier-plugin-organize-imports"),
38
- require.resolve("prettier-plugin-packagejson"),
39
- require.resolve("prettier-plugin-sort-json"),
40
- require.resolve("@trivago/prettier-plugin-sort-imports")
41
- ],
42
- printWidth: 100,
43
- proseWrap: "never",
44
- singleQuote: true,
45
- trailingComma: "all",
36
+ importOrder: ["<THIRD_PARTY_MODULES>", "^@/(.*)$", "^[./]"],
46
37
  importOrderSeparation: true,
47
38
  importOrderSortSpecifiers: true,
48
- importOrder: ["<THIRD_PARTY_MODULES>", "^@/(.*)$", "^[./]"],
49
39
  overrides: [
50
40
  {
51
41
  files: "*.md",
@@ -53,5 +43,15 @@ var prettier_default = {
53
43
  proseWrap: "preserve"
54
44
  }
55
45
  }
56
- ]
46
+ ],
47
+ plugins: [
48
+ require.resolve("prettier-plugin-organize-imports"),
49
+ require.resolve("prettier-plugin-packagejson"),
50
+ require.resolve("prettier-plugin-sort-json"),
51
+ require.resolve("@trivago/prettier-plugin-sort-imports")
52
+ ],
53
+ printWidth: 100,
54
+ proseWrap: "never",
55
+ singleQuote: true,
56
+ trailingComma: "all"
57
57
  };
@@ -1,2 +1,3 @@
1
- declare const _default: any;
1
+ /// <reference types="semantic-release" />
2
+ declare const _default: import("semantic-release").Options;
2
3
  export default _default;
@@ -22,71 +22,72 @@ __export(semantic_release_exports, {
22
22
  default: () => semantic_release_default
23
23
  });
24
24
  module.exports = __toCommonJS(semantic_release_exports);
25
- var { createConfig } = require("semantic-release-config-gitmoji/lib/createConfig");
26
- var semantic_release_default = createConfig({
25
+ var import_createConfig = require("semantic-release-config-gitmoji/lib/createConfig");
26
+ var options = {
27
27
  changelogTitle: `<a name="readme-top"></a>
28
28
 
29
29
  # Changelog`,
30
30
  releaseRules: [
31
31
  {
32
- type: "feat",
33
- release: "minor"
32
+ release: "minor",
33
+ type: "feat"
34
34
  },
35
35
  {
36
- type: "fix",
37
- release: "patch"
36
+ release: "patch",
37
+ type: "fix"
38
38
  },
39
39
  {
40
- type: "perf",
41
- release: "patch"
40
+ release: "patch",
41
+ type: "perf"
42
42
  },
43
43
  {
44
- type: "style",
45
- release: "patch"
44
+ release: "patch",
45
+ type: "style"
46
46
  },
47
47
  {
48
- type: "refactor",
49
- release: "patch"
48
+ release: "patch",
49
+ type: "refactor"
50
50
  },
51
51
  {
52
- type: "build",
53
- release: "patch"
52
+ release: "patch",
53
+ type: "build"
54
54
  },
55
- { type: "docs", scope: "README", release: "patch" },
56
- { type: "docs", scope: "README.md", release: "patch" },
57
- { type: "docs", release: false },
55
+ { release: "patch", scope: "README", type: "docs" },
56
+ { release: "patch", scope: "README.md", type: "docs" },
57
+ { release: false, type: "docs" },
58
58
  {
59
- type: "test",
60
- release: false
59
+ release: false,
60
+ type: "test"
61
61
  },
62
62
  {
63
- type: "ci",
64
- release: false
63
+ release: false,
64
+ type: "ci"
65
65
  },
66
66
  {
67
- type: "chore",
68
- release: false
67
+ release: false,
68
+ type: "chore"
69
69
  },
70
70
  {
71
- type: "wip",
72
- release: false
71
+ release: false,
72
+ type: "wip"
73
73
  },
74
74
  {
75
- type: "BREAKING CHANGE",
76
- release: "major"
75
+ release: "major",
76
+ type: "BREAKING CHANGE"
77
77
  },
78
78
  {
79
- scope: "BREAKING CHANGE",
80
- release: "major"
79
+ release: "major",
80
+ scope: "BREAKING CHANGE"
81
81
  },
82
82
  {
83
- subject: "*BREAKING CHANGE*",
84
- release: "major"
83
+ release: "major",
84
+ subject: "*BREAKING CHANGE*"
85
85
  },
86
- { subject: "*force release*", release: "patch" },
87
- { subject: "*force patch*", release: "patch" },
88
- { subject: "*force minor*", release: "minor" },
89
- { subject: "*force major*", release: "major" },
90
- { subject: "*skip release*", release: false }
86
+ { release: "patch", subject: "*force release*" },
87
+ { release: "patch", subject: "*force patch*" },
88
+ { release: "minor", subject: "*force minor*" },
89
+ { release: "major", subject: "*force major*" },
90
+ { release: false, subject: "*skip release*" }
91
91
  ]
92
- });
92
+ };
93
+ var semantic_release_default = (0, import_createConfig.createConfig)(options);
@@ -1,36 +1,36 @@
1
1
  declare const _default: {
2
2
  extends: string[];
3
- plugins: string[];
4
3
  overrides: ({
4
+ customSyntax: string;
5
5
  files: string[];
6
6
  plugins: string[];
7
- customSyntax: string;
8
7
  rules: {
9
- 'function-no-unknown': null;
10
- 'at-rule-no-unknown': null;
8
+ 'at-rule-no-unknown': undefined;
11
9
  'color-no-invalid-hex': boolean;
10
+ 'function-no-unknown': undefined;
12
11
  'less/color-no-invalid-hex': boolean;
13
- 'value-no-vendor-prefix'?: undefined;
14
- 'property-no-vendor-prefix'?: undefined;
15
12
  'no-empty-source'?: undefined;
16
- 'no-missing-end-of-source-newline'?: undefined;
17
13
  'no-invalid-double-slash-comments'?: undefined;
14
+ 'no-missing-end-of-source-newline'?: undefined;
15
+ 'property-no-vendor-prefix'?: undefined;
16
+ 'value-no-vendor-prefix'?: undefined;
18
17
  };
19
18
  } | {
20
- files: string[];
21
19
  customSyntax: string;
20
+ files: string[];
22
21
  rules: {
23
- 'value-no-vendor-prefix': boolean;
22
+ 'no-empty-source': undefined;
23
+ 'no-invalid-double-slash-comments': undefined;
24
+ 'no-missing-end-of-source-newline': undefined;
24
25
  'property-no-vendor-prefix': boolean;
25
- 'no-empty-source': null;
26
- 'no-missing-end-of-source-newline': null;
27
- 'no-invalid-double-slash-comments': null;
28
- 'function-no-unknown'?: undefined;
26
+ 'value-no-vendor-prefix': boolean;
29
27
  'at-rule-no-unknown'?: undefined;
30
28
  'color-no-invalid-hex'?: undefined;
29
+ 'function-no-unknown'?: undefined;
31
30
  'less/color-no-invalid-hex'?: undefined;
32
31
  };
33
32
  plugins?: undefined;
34
33
  })[];
34
+ plugins: string[];
35
35
  };
36
36
  export default _default;
@@ -38,29 +38,29 @@ var stylelint_default = {
38
38
  require.resolve("@umijs/lint/dist/config/stylelint"),
39
39
  "stylelint-config-clean-order"
40
40
  ],
41
- plugins: ["stylelint-order"],
42
41
  overrides: [
43
42
  {
43
+ customSyntax: "postcss-less",
44
44
  files: ["*.less", "*.css"],
45
45
  plugins: ["stylelint-less"],
46
- customSyntax: "postcss-less",
47
46
  rules: {
48
- "function-no-unknown": null,
49
- "at-rule-no-unknown": null,
47
+ "at-rule-no-unknown": void 0,
50
48
  "color-no-invalid-hex": true,
49
+ "function-no-unknown": void 0,
51
50
  "less/color-no-invalid-hex": true
52
51
  }
53
52
  },
54
53
  {
55
- files: ["*.js", "*.jsx", "*.ts", "*.tsx"],
56
54
  customSyntax: "postcss-styled-syntax",
55
+ files: ["*.js", "*.jsx", "*.ts", "*.tsx"],
57
56
  rules: {
58
- "value-no-vendor-prefix": true,
57
+ "no-empty-source": void 0,
58
+ "no-invalid-double-slash-comments": void 0,
59
+ "no-missing-end-of-source-newline": void 0,
59
60
  "property-no-vendor-prefix": true,
60
- "no-empty-source": null,
61
- "no-missing-end-of-source-newline": null,
62
- "no-invalid-double-slash-comments": null
61
+ "value-no-vendor-prefix": true
63
62
  }
64
63
  }
65
- ]
64
+ ],
65
+ plugins: ["stylelint-order"]
66
66
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/lint",
3
- "version": "1.5.0",
3
+ "version": "1.6.0",
4
4
  "homepage": "https://github.com/lobehub/lobe-lint",
5
5
  "bugs": {
6
6
  "url": "https://github.com/lobehub/lobe-lint/issues/new"
@@ -25,7 +25,9 @@
25
25
  "eslint-import-resolver-typescript": "latest",
26
26
  "eslint-plugin-import": "latest",
27
27
  "eslint-plugin-simple-import-sort": "latest",
28
+ "eslint-plugin-sort-keys-fix": "latest",
28
29
  "eslint-plugin-typescript-sort-keys": "latest",
30
+ "eslint-plugin-unicorn": "latest",
29
31
  "eslint-plugin-unused-imports": "latest",
30
32
  "postcss-less": "latest",
31
33
  "postcss-styled-syntax": "latest",