Skip to content

Commit f44bd2c

Browse files
🔧 chore: update lint config
1 parent d7f6cb0 commit f44bd2c

File tree

90 files changed

+141
-206
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+141
-206
lines changed

.changelogrc.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1 @@
1-
// See https://github.com/arvinxx/gitmoji-commit-workflow/tree/master/packages/changelog#readme
2-
module.exports = {
3-
displayTypes: ['feat', 'fix', 'styles', 'pref', 'build'],
4-
};
1+
module.exports = require('@lobehub/lint/dist/commitlint');

.commitlintrc.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
module.exports = {
2-
extends: ['gitmoji'],
3-
};
1+
module.exports = require('@lobehub/lint/dist/commitlint');

.dumirc.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { defineConfig } from 'dumi';
2+
23
import { homepage, name } from './package.json';
34

45
const isProd = process.env.NODE_ENV === 'production';

.eslintrc.js

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1 @@
1-
module.exports = {
2-
extends: require.resolve('@umijs/lint/dist/config/eslint'),
3-
plugins: ['simple-import-sort', 'import', 'typescript-sort-keys'],
4-
rules: {
5-
'simple-import-sort/imports': 'error',
6-
'simple-import-sort/exports': 'error',
7-
'import/first': 'error',
8-
'import/newline-after-import': 'error',
9-
'import/no-duplicates': 'error',
10-
'typescript-sort-keys/interface': 'error',
11-
'typescript-sort-keys/string-enum': 'error',
12-
'react/jsx-sort-props': 'error',
13-
'react/jsx-no-useless-fragment': 'error',
14-
},
15-
};
1+
module.exports = require('@lobehub/lint/dist/eslint');

.npmrc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,10 @@
11
lockfile=false
22
resolution-mode=highest
3+
public-hoist-pattern[]=*@umijs/lint*
4+
public-hoist-pattern[]=*remark*
5+
public-hoist-pattern[]=*eslint*
6+
public-hoist-pattern[]=*stylelint*
7+
public-hoist-pattern[]=*prettier*
8+
public-hoist-pattern[]=*commitlint*
9+
public-hoist-pattern[]=*postcss*
10+
public-hoist-pattern[]=*semantic-release*

.prettierignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
**/*.svg
22
.umi
33
.umi-production
4+
.idea
5+
.husky
46
/dist
57
.dockerignore
68
.DS_Store

.prettierrc.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1 @@
1-
module.exports = {
2-
pluginSearchDirs: false,
3-
plugins: [
4-
require.resolve('prettier-plugin-organize-imports'),
5-
require.resolve('prettier-plugin-packagejson'),
6-
],
7-
printWidth: 100,
8-
proseWrap: 'never',
9-
singleQuote: true,
10-
trailingComma: 'all',
11-
overrides: [
12-
{
13-
files: '*.md',
14-
options: {
15-
proseWrap: 'preserve',
16-
},
17-
},
18-
],
19-
};
1+
module.exports = require('@lobehub/lint/dist/prettier');

.releaserc.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
module.exports = {
2-
extends: ['semantic-release-config-gitmoji'],
3-
};
1+
module.exports = require('@lobehub/lint/dist/semantic-release');

.remarkrc.js

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1 @@
1-
module.exports = {
2-
plugins: [
3-
'remark-frontmatter',
4-
'remark-lint-frontmatter-schema',
5-
'remark-preset-lint-recommended',
6-
['remark-lint-list-item-indent', 'space'],
7-
['remark-lint-no-literal-urls', false],
8-
['remark-toc', { heading: 'TOC', maxDepth: 3 }],
9-
],
10-
};
1+
module.exports = require('@lobehub/lint/dist/remarklint');

.stylelintrc.js

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
module.exports = {
2-
extends: ['stylelint-config-recommended', 'stylelint-config-clean-order'],
3-
files: ['*.js', '*.jsx', '*.ts', '*.tsx'],
4-
plugins: ['stylelint-order'],
5-
customSyntax: 'postcss-styled-syntax',
2+
extends: require.resolve('@lobehub/lint/dist/stylelint'),
63
rules: {
7-
'no-empty-source': null,
8-
'no-invalid-double-slash-comments': null,
4+
'custom-property-pattern': null,
5+
'selector-pseudo-element-no-unknown': null,
96
},
107
};

0 commit comments

Comments
 (0)