Skip to content

Commit

Permalink
chore: fix eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnCampionJr committed Dec 16, 2023
1 parent 8e76bad commit d10ac31
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 7 deletions.
43 changes: 43 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
// Enable the ESlint flat config support
"eslint.experimental.useFlatConfig": true,

// Disable the default formatter, use eslint instead
"prettier.enable": false,
"editor.formatOnSave": false,

// Auto fix
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit",
"source.organizeImports": "never"
},

// Silent the stylistic rules in you IDE, but still auto fix them
"eslint.rules.customizations": [
{ "rule": "style/*", "severity": "off" },
{ "rule": "format/*", "severity": "off" },
{ "rule": "*-indent", "severity": "off" },
{ "rule": "*-spacing", "severity": "off" },
{ "rule": "*-spaces", "severity": "off" },
{ "rule": "*-order", "severity": "off" },
{ "rule": "*-dangle", "severity": "off" },
{ "rule": "*-newline", "severity": "off" },
{ "rule": "*quotes", "severity": "off" },
{ "rule": "*semi", "severity": "off" }
],

// Enable eslint for all supported languages
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact",
"vue",
"html",
"markdown",
"json",
"jsonc",
"yaml",
"toml"
]
}
10 changes: 3 additions & 7 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
import antfu from '@antfu/eslint-config'
// eslint.config.js
const antfu = require('@antfu/eslint-config').default

export default antfu(
{
unocss: true,
formatters: true,
},
)
module.exports = antfu()

0 comments on commit d10ac31

Please sign in to comment.