Skip to content

Commit 4f7d214

Browse files
微信公众号:储凡mmdapl
微信公众号:储凡
andauthored
feat: 移除antfu/eslint-config模块,使用@142vip/eslint-config替换,修复配置异常 (#177)
* feat: 移除`antfu/eslint-config`模块,使用`@142vip/eslint-config`替换,修复配置异常 * chore: update --------- Co-authored-by: chufan <[email protected]>
1 parent 9e238ab commit 4f7d214

File tree

4 files changed

+678
-756
lines changed

4 files changed

+678
-756
lines changed

docs/.vuepress/theme/theme.ts

+21-3
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,14 @@ export const themeConfig = {
1313
theme: hopeTheme({
1414
locales: i18n,
1515
// navbarIcon: false,
16-
// 禁用深色模式
16+
// 在深色模式和浅色模式之间切换
1717
darkmode: 'toggle',
1818
// 支持全屏
1919
// fullscreen: true,
2020
// 纯净模式
2121
// pure: true,
22-
print: false, // 打印按钮
22+
// 打印按钮
23+
print: false,
2324
hostname: 'https://142vip.cn',
2425
author: AUTHOR_INFO,
2526
favicon: '/favicon.ico',
@@ -176,7 +177,24 @@ export const themeConfig = {
176177
},
177178
// 代码高亮:https://theme-hope.vuejs.press/zh/guide/feature/code-block.html
178179
shiki: {
179-
langs: ['ts', 'js', 'json', 'vue', 'json5', 'bash', 'diff', 'c', 'c++', 'dockerfile', 'nginx', 'proto', 'java', 'javascript', 'typescript'],
180+
langs: [
181+
'ts',
182+
'js',
183+
'json',
184+
'vue',
185+
'json5',
186+
'bash',
187+
'diff',
188+
'c',
189+
'c++',
190+
'dockerfile',
191+
'nginx',
192+
'proto',
193+
'java',
194+
'javascript',
195+
'typescript',
196+
'yaml',
197+
],
180198
// 你想要使用的主题
181199
themes: {
182200
light: 'one-light',

eslint.config.js

+2-21
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,9 @@
1-
import antFu from '@antfu/eslint-config'
1+
import { defineVipEslintConfig } from '@142vip/eslint-config'
22

3-
// 参考:https://github.com/antfu/eslint-config
4-
export default antFu({
3+
export default defineVipEslintConfig({
54
ignores: [
65
'**/CHANGELOG.md',
76
],
8-
gitignore: true,
9-
typescript: true,
10-
vue: true,
11-
jsonc: true,
12-
yaml: true,
13-
formatters: {
14-
css: true,
15-
html: true,
16-
markdown: 'prettier',
17-
},
187
rules: {
19-
'no-console': 'warn',
20-
'no-restricted-syntax': [
21-
'warn',
22-
{
23-
selector: 'CallExpression[callee.object.name=\'console\'][callee.property.name!=/^(log|warn|error|info|trace)$/]',
24-
message: 'Unexpected property on console object was called',
25-
},
26-
],
278
},
289
})

package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,19 @@
2727
"release": "npx fa release --vip"
2828
},
2929
"devDependencies": {
30+
"@142vip/eslint-config": "^0.0.1-alpha.2",
3031
"@142vip/fairy-cli": "^0.0.3-alpha.13",
3132
"@142vip/utils": "^0.0.1-alpha.5",
32-
"@antfu/eslint-config": "^2.27.3",
3333
"@vue/repl": "^4.3.1",
3434
"@vuepress/bundler-vite": "2.0.0-rc.15",
3535
"@vuepress/plugin-markdown-image": "2.0.0-rc.30",
36+
"dashjs": "^4.7.4",
3637
"eslint": "8.55.0",
3738
"hls.js": "^1.5.13",
3839
"mermaid": "^10.9.1",
3940
"only-allow": "^1.2.1",
4041
"reveal.js": "^5.1.0",
42+
"sass-embedded": "^1.79.4",
4143
"simple-git-hooks": "^2.11.1",
4244
"typescript": "^5.5.4",
4345
"vercel": "^32.7.2",

0 commit comments

Comments
 (0)