⚙️ chore (eslint): configure eslint and prettier
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"useTabs": false,
|
||||
"tabWidth": 2,
|
||||
"singleQuote": true,
|
||||
"trailingComma": "es5",
|
||||
"printWidth": 120,
|
||||
"semi": false,
|
||||
"plugins": ["prettier-plugin-tailwindcss"]
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
import antfu from "@antfu/eslint-config";
|
||||
import withNuxt from "./.nuxt/eslint.config.mjs";
|
||||
|
||||
export default withNuxt(
|
||||
antfu(
|
||||
{
|
||||
unocss: true,
|
||||
formatters: true,
|
||||
// Relaxed stylistic options
|
||||
stylistic: {
|
||||
semi: false,
|
||||
quotes: "single",
|
||||
// Less strict formatting
|
||||
jsx: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
rules: {
|
||||
// Basic rules
|
||||
quotes: ["error", "single", { avoidEscape: true }],
|
||||
"style/no-trailing-spaces": ["error", { ignoreComments: true }],
|
||||
|
||||
// Relax strict formatting rules
|
||||
"style/brace-style": "off", // Allow inline if
|
||||
curly: ["error", "multi-line"], // Only require braces for multi-line
|
||||
"style/arrow-parens": "off",
|
||||
|
||||
// UnoCSS - make it warning instead of error, or disable completely
|
||||
"unocss/order": "off", // atau 'off' untuk disable
|
||||
|
||||
// Vue specific - relax template formatting
|
||||
"vue/html-indent": "off",
|
||||
"vue/max-attributes-per-line": "off",
|
||||
"vue/singleline-html-element-content-newline": "off",
|
||||
"vue/multiline-html-element-content-newline": "off",
|
||||
"vue/html-self-closing": "off",
|
||||
|
||||
// Allow more flexible code style
|
||||
"style/max-statements-per-line": ["error", { max: 3 }],
|
||||
"antfu/if-newline": "off", // Disable newline after if requirement
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ["**/*.md"],
|
||||
rules: {
|
||||
"style/no-trailing-spaces": "off",
|
||||
},
|
||||
},
|
||||
),
|
||||
);
|
||||
+45
-2
@@ -7,11 +7,54 @@
|
||||
"dev": "nuxt dev",
|
||||
"generate": "nuxt generate",
|
||||
"preview": "nuxt preview",
|
||||
"postinstall": "nuxt prepare"
|
||||
"postinstall": "nuxt prepare",
|
||||
"typecheck": "vue-tsc --noEmit",
|
||||
"lint": "eslint .",
|
||||
"format": "eslint --fix ."
|
||||
},
|
||||
"dependencies": {
|
||||
"@iconify-json/lucide": "^1.2.30",
|
||||
"@iconify-json/radix-icons": "^1.2.2",
|
||||
"@internationalized/date": "^3.7.0",
|
||||
"@unovis/ts": "^1.5.1",
|
||||
"@unovis/vue": "^1.5.1",
|
||||
"embla-carousel": "^8.5.2",
|
||||
"embla-carousel-vue": "^8.5.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@antfu/eslint-config": "^4.10.1",
|
||||
"@nuxt/eslint": "^1.2.0",
|
||||
"prettier": "^3.6.2",
|
||||
"prettier-plugin-tailwindcss": "^0.5.14",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"@nuxt/icon": "^1.11.0",
|
||||
"@nuxtjs/color-mode": "^3.5.2",
|
||||
"@pinia/nuxt": "^0.5.1",
|
||||
"@unocss/eslint-plugin": "^66.0.0",
|
||||
"@unocss/nuxt": "^66.0.0",
|
||||
"@vee-validate/zod": "^4.15.0",
|
||||
"@vueuse/core": "^12.2.0",
|
||||
"@vueuse/math": "^12.2.0",
|
||||
"@vueuse/nuxt": "^12.2.0",
|
||||
"class-variance-authority": "^0.7.1",
|
||||
"clsx": "^2.1.1",
|
||||
"eslint": "^9.22.0",
|
||||
"eslint-plugin-format": "^1.0.1",
|
||||
"lucide-vue-next": "^0.482.0",
|
||||
"nuxt": "^4.0.1",
|
||||
"radix-vue": "^1.9.17",
|
||||
"shadcn-nuxt": "^0.10.4",
|
||||
"tailwind-merge": "^2.6.0",
|
||||
"typescript": "^5.8.2",
|
||||
"unocss": "^66.0.0",
|
||||
"unocss-preset-animations": "^1.1.1",
|
||||
"unocss-preset-shadcn": "^0.5.0",
|
||||
"vaul-vue": "^0.2.0",
|
||||
"vee-validate": "^4.15.0",
|
||||
"vue": "^3.5.18",
|
||||
"vue-router": "^4.5.1"
|
||||
"vue-router": "^4.5.1",
|
||||
"vue-sonner": "^1.3.0",
|
||||
"vue-tsc": "^2.1.10",
|
||||
"zod": "^3.24.2"
|
||||
}
|
||||
}
|
||||
|
||||
Generated
+8733
-4763
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user