코드 컨벤션

ESLint, Prettier 설정

.eslintrc.json

{
  "env": {
    "browser": true,
    "es2021": true,
    "node": true
  },
  "extends": [
    "eslint:recommended",
    "plugin:react/recommended",
    "plugin:@typescript-eslint/recommended",
    "next/core-web-vitals",
    "airbnb",
    "airbnb/hooks",
    "airbnb-typescript",
    "prettier"
  ],
  "overrides": [],
  "parser": "@typescript-eslint/parser",
  "parserOptions": {
    "ecmaVersion": "latest",
    "sourceType": "module",
    "project": ["tsconfig.json"]
  },
  "plugins": ["react", "@typescript-eslint"],
  "rules": {
    **"react/react-in-jsx-scope": "off",
    "react/jsx-props-no-spreading": "off",**
    **"jsx-a11y/click-events-have-key-events": "off",
    "jsx-a11y/no-static-element-interactions": "off",**
    **"react/require-default-props": "off",**
    **"jsx-a11y/no-noninteractive-element-interactions": "off",**
    "react/button-has-type": "off",
    "react/jsx-no-useless-fragment": "off",
    **"import/prefer-default-export": "off",**
    "react-hooks/exhaustive-deps": "off",
    "consistent-return": "off",
    "react/no-array-index-key": "off",
    "no-await-in-loop": "off",
    "no-plusplus": "off",
    "no-param-reassign": "off",
    "@typescript-eslint/no-explicit-any": "off", //kakao에서만
    "@typescript-eslint/no-unused-vars": "off",
    "prefer-destructuring": "off",
    "@typescript-eslint/no-shadow": "off",
    **"jsx-a11y/label-has-associated-control": "off"**
  }
}

.prettierrc

{
  "printWidth": 80, //default 80 넣을 필요 없음
  "tabWidth": 2, //default 2라 넣을 필요 없음
  "singleQuote": true,
  "jsxSingleQuote": true,
  "trailingComma": "all", 
  "arrowParens": "avoid",
  "endOfLine": "auto"
}

StyleLint 설정