VsCode

extentions

eslint-prettier 옵션

rules: {
    // "no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
    // "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off"
    "no-console": "off",
    // "no-console": process.env.NODE_ENV === "production" ? "error" : "off",
    // "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off"
    "prettier/prettier": ['error', {
      singleQuote: true,
      semi: true,
      useTabs: false,
      tabWidth: 2,
      trailingComma: 'all',
      printWidth: 80,
      bracketSpacing: true,
      arrowParens: 'avoid',
    }]
  },

설정에서 eslint option에 추가

"eslint.validate": [
        
        {
            "language": "javascript",
            "autoFix": true
        },
        {
            "language": "vue",
            "autoFix": true
        }
    ],

설정에서 format on save 체크해제</br>

jsconfig.json

src alias 설정

{
    "compilerOptions": {
        "baseUrl": ".",
        "paths": {
            "~/*": [
                "./*"
            ],
            "@/*": [
                "./src/*"
            ]
        }
    },
    "exclude": [
        "node_modules",
        "dist"
    ]
}