[VSCODE]프리티어 Prettier & ESLint/파일 저장하면 자동 들여쓰기, 세미콜론 Extentions

최예린·2022년 12월 17일
0

기타

목록 보기
4/5

vscode에 확장프로그램 설치



위 두가지 프로그램을 모두 설치합니다.
작성자를 잘 확인해서 설치해야합니다.

뷰티파이는 프리티어와 충돌이 있을 수 있기때문에 사용한 적있다면 삭제하는 것이 좋습니다.

eslintrc

{
  "extends": ["react-app", "prettier"]
}

Ctrl + Shift + P

{
  "editor.formatOnSave": true,
  "editor.defaultFormatter": "esbenp.prettier-vscode",
  "editor.codeActionsOnSave": {
    "source.fixAll.eslint": true
  }
}

.prettierrc

{
  "trailingComma": "all",
  "tabWidth": 4,
  "semi": false,
  "singleQuote": true
}

.vscode/settings.json

{
    "editor.formatOnSave": true,
    "editor.defaultFormatter": "esbenp.prettier-vscode",
    "editor.codeActionsOnSave": {
      "source.fixAll.eslint": true
    }
}
profile
경북대학교 글로벌소프트웨어융합전공/미디어아트연계전공

0개의 댓글