Commit 2d05af15 authored by malyusgun's avatar malyusgun
Browse files

project configuration (eslint)

parent 6adfe2b3
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -14,8 +14,6 @@
      "RouteLocationRaw",
      "VNode",
      "WritableComputedRef",
      "[alias]",
      "[import-names]",
      "axios",
      "computed",
      "createApp",

.eslintrc.cjs

deleted100644 → 0
+0 −15
Original line number Diff line number Diff line
/* eslint-env node */
require('@rushstack/eslint-patch/modern-module-resolution')

module.exports = {
  root: true,
  'extends': [
    'plugin:vue/vue3-essential',
    'eslint:recommended',
    '@vue/eslint-config-typescript',
    '@vue/eslint-config-prettier/skip-formatting'
  ],
  parserOptions: {
    ecmaVersion: 'latest'
  },
}

.eslintrc.json

0 → 100644
+78 −0
Original line number Diff line number Diff line
{
  "env": {
    "browser": true,
    "es2021": true,
    "node": true
  },
  "extends": [
    "eslint:recommended",
    "plugin:@typescript-eslint/recommended",
    "plugin:vue/base",
    "plugin:vue/vue3-essential",
    "plugin:vue/vue3-strongly-recommended",
    "plugin:vue/vue3-recommended",
    "prettier"
  ],
  "parserOptions": {
    "ecmaVersion": "latest",
    "parser": "@typescript-eslint/parser",
    "sourceType": "module"
  },
  "plugins": ["vue", "@typescript-eslint", "prettier"],
  "ignorePatterns": ["*.json", "*.html"],
  "rules": {
    "no-undef": "off",
    "vue/no-unused-vars": "warn",
    "no-unused-vars": "warn",
    "no-empty-function": "warn",
    "@typescript-eslint/no-empty-function": "warn",

    "prettier/prettier": [
      "error",
      {
        "tabWidth": 2,
        "semi": true,
        "singleQuote": true,
        "arrowParens": "always",
        "printWidth": 100,
        "bracketSpacing": true,
        "vueIndentScriptAndStyle": false,
        "endOfLine": "auto"
      }
    ],
    "radix": "off",
    "camelcase": "off",
    "global-require": "off",
    "object-curly-newline": "off",
    "import/first": "off",
    "import/extensions": "off",
    "import/prefer-default-export": "off",
    "import/no-extraneous-dependencies": "off",
    "import/named": "off",
    "no-return-assign": ["error", "except-parens"],
    "no-plusplus": ["error", { "allowForLoopAfterthoughts": true }],
    "no-param-reassign": "off",
    "no-confusing-arrow": "off",
    "no-unused-expressions": "off",
    "no-shadow": "off",
    "no-restricted-syntax": "off",
    "no-use-before-define": "off",
    "no-redeclare": "off",
    "@typescript-eslint/no-redeclare": ["error"],
    "@typescript-eslint/no-use-before-define": "error",
    "@typescript-eslint/no-shadow": "error",
    "@typescript-eslint/no-unused-expressions": "error",
    "@typescript-eslint/no-var-requires": "off",
    "@typescript-eslint/explicit-module-boundary-types": "off",
    "@typescript-eslint/no-non-null-assertion": "off",
    "@typescript-eslint/ban-ts-comment": ["error", { "ts-ignore": "allow-with-description" }],
    "vue/attribute-hyphenation": "off",
    "vue/no-v-html": "off",
    "vue/max-attributes-per-line": "off",
    "vue/no-v-model-argument": "off",
    "vue/v-on-event-hyphenation": "off",
    "vue/require-default-prop": "off",
    "vue/no-multiple-template-root": "off",
    "vue/multi-word-component-names": "off"
  }
}
+1 −0
Original line number Diff line number Diff line
@@ -2,5 +2,6 @@
  <profile version="1.0">
    <option name="myName" value="Project Default" />
    <inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
    <inspection_tool class="TsLint" enabled="true" level="WARNING" enabled_by_default="true" />
  </profile>
</component>
 No newline at end of file
+19 −0
Original line number Diff line number Diff line
@@ -31,8 +31,11 @@
    "@rushstack/eslint-patch": "^1.8.0",
    "@tsconfig/node20": "^20.1.4",
    "@types/node": "^20.14.5",
    "@vue/cli-plugin-eslint": "~5.0.0",
    "@vue/cli-service": "~5.0.0",
    "@types/uuid": "^10.0.0",
    "@vitejs/plugin-vue": "^5.0.5",
    "@vue/cli-plugin-typescript": "~5.0.0",
    "@vue/eslint-config-prettier": "^9.0.0",
    "@vue/eslint-config-typescript": "^13.0.0",
    "@vue/tsconfig": "^0.5.1",
@@ -47,5 +50,21 @@
    "unplugin-vue-components": "^0.27.3",
    "vite": "^5.3.1",
    "vue-tsc": "^2.0.21"
  },
  "eslintConfig": {
    "root": true,
    "env": {
      "node": true
    },
    "extends": [
      "plugin:vue/vue3-essential",
      "eslint:recommended",
      "@vue/typescript/recommended",
      "plugin:prettier/recommended"
    ],
    "parserOptions": {
      "ecmaVersion": 2020
    },
    "rules": {}
  }
}
Loading