Skip to content

Commit

Permalink
更新 ESLint 配置,测试Markdown 文件支持
Browse files Browse the repository at this point in the history
  • Loading branch information
lvzhenbo committed Nov 8, 2024
1 parent 0740d6b commit ef0961b
Show file tree
Hide file tree
Showing 3 changed files with 903 additions and 340 deletions.
12 changes: 12 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import vueTsEslintConfig from '@vue/eslint-config-typescript';
import prettierConfig from '@vue/eslint-config-prettier';
import parserVue from 'vue-eslint-parser';
import AutoImport from './.eslintrc-auto-import.json' with { type: 'json' };
import markdown from '@eslint/markdown';

export default defineFlatConfig([
...pluginVue.configs['flat/recommended'],
Expand Down Expand Up @@ -64,4 +65,15 @@ export default defineFlatConfig([
ignores: ['**/dist/**', '**/dist-ssr/**', '**/coverage/**'],
},
prettierConfig,
{
name: 'app/markdown-files',
files: ['**/*.md'],
plugins: {
markdown,
},
language: 'markdown/commonmark',
rules: {
'markdown/no-html': 'error',
},
},
]);
13 changes: 7 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,21 @@
},
"devDependencies": {
"@crxjs/vite-plugin": "2.0.0-beta.28",
"@eslint/js": "^9.13.0",
"@eslint/js": "^9.14.0",
"@eslint/markdown": "^6.2.1",
"@rushstack/eslint-patch": "^1.10.4",
"@tsconfig/node18": "^18.2.4",
"@types/chrome": "^0.0.279",
"@types/node": "^22.8.1",
"@types/chrome": "^0.0.280",
"@types/node": "^22.9.0",
"@vitejs/plugin-vue": "^5.1.4",
"@vitejs/plugin-vue-jsx": "^4.0.1",
"@vue/eslint-config-prettier": "^10.1.0",
"@vue/eslint-config-typescript": "^14.1.3",
"@vue/tsconfig": "^0.5.1",
"autoprefixer": "^10.4.20",
"eslint": "^9.13.0",
"eslint": "^9.14.0",
"eslint-define-config": "^2.1.0",
"eslint-plugin-vue": "^9.29.1",
"eslint-plugin-vue": "^9.30.0",
"npm-run-all2": "^7.0.1",
"postcss": "^8.4.47",
"prettier": "^3.3.3",
Expand All @@ -45,7 +46,7 @@
"unplugin-vue-components": "^0.27.4",
"vite": "^5.4.10",
"vue-eslint-parser": "^9.4.3",
"vue-tsc": "^2.1.8"
"vue-tsc": "^2.1.10"
},
"packageManager": "[email protected]+sha512.22721b3a11f81661ae1ec68ce1a7b879425a1ca5b991c975b074ac220b187ce56c708fe5db69f4c962c989452eee76c82877f4ee80f474cebd61ee13461b6228"
}
Loading

0 comments on commit ef0961b

Please sign in to comment.