Set up eslint
This commit is contained in:
parent
4c8a22368d
commit
de4574f938
3 changed files with 1044 additions and 2 deletions
1013
pnpm-lock.yaml
generated
1013
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load diff
23
showbits-thermal-printer-ui/eslint.config.js
Normal file
23
showbits-thermal-printer-ui/eslint.config.js
Normal file
|
|
@ -0,0 +1,23 @@
|
||||||
|
import eslint from "@eslint/js";
|
||||||
|
import prettier from "eslint-config-prettier";
|
||||||
|
import vue from "eslint-plugin-vue";
|
||||||
|
import globals from "globals";
|
||||||
|
import tseslint from "typescript-eslint";
|
||||||
|
|
||||||
|
export default tseslint.config(
|
||||||
|
{ files: ["**/*.{js,mjs,cjs,ts,vue}"] },
|
||||||
|
{ ignores: ["dist/"] },
|
||||||
|
|
||||||
|
{ languageOptions: { globals: { ...globals.browser, ...globals.node } } },
|
||||||
|
|
||||||
|
eslint.configs.recommended,
|
||||||
|
...tseslint.configs.strict,
|
||||||
|
...tseslint.configs.stylistic,
|
||||||
|
...vue.configs["flat/recommended"],
|
||||||
|
prettier,
|
||||||
|
|
||||||
|
{
|
||||||
|
files: ["**/*.vue"],
|
||||||
|
languageOptions: { parserOptions: { parser: tseslint.parser } },
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
@ -5,17 +5,23 @@
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
"check": "vue-tsc -b",
|
"check": "vue-tsc -b && eslint",
|
||||||
"build": "vue-tsc -b && vite build",
|
"build": "pnpm check && vite build",
|
||||||
"preview": "vite preview"
|
"preview": "vite preview"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"vue": "^3.5.13"
|
"vue": "^3.5.13"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@eslint/js": "^9.21.0",
|
||||||
"@vitejs/plugin-vue": "^5.2.1",
|
"@vitejs/plugin-vue": "^5.2.1",
|
||||||
"@vue/tsconfig": "^0.7.0",
|
"@vue/tsconfig": "^0.7.0",
|
||||||
|
"eslint": "^9.21.0",
|
||||||
|
"eslint-config-prettier": "^10.0.2",
|
||||||
|
"eslint-plugin-vue": "^9.32.0",
|
||||||
|
"globals": "^16.0.0",
|
||||||
"typescript": "~5.7.3",
|
"typescript": "~5.7.3",
|
||||||
|
"typescript-eslint": "^8.25.0",
|
||||||
"vite": "^6.2.0",
|
"vite": "^6.2.0",
|
||||||
"vite-plugin-vue-devtools": "^7.7.2",
|
"vite-plugin-vue-devtools": "^7.7.2",
|
||||||
"vue-tsc": "^2.2.8"
|
"vue-tsc": "^2.2.8"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue