본문 바로가기

React19

[React Error] is assigned a value but never used. 'UPLOAD_FILE'이(가) 선언은 되었지만 해당 값이 읽히지는 않았습니다. . . . export export export export.....!!! 2022. 2. 8.
[React Error] error - Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object. You likely forgot to export your component from the file it's defined in, or you might have.. 오늘도 어김없이 에러가 났다. 에러문구는 다음과 같다. error - Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports. export 또는 import를 안해줬거나 default를 빼먹은 모양인데 광활한 컴포넌트들 속에서 하나하나 찾아봤다. 나의 경우는 페이지네이션 하려고 컴포넌트 빼.. 2022. 2. 8.
[TypeError] error - TypeError: Cannot read properties of undefined (reading 'fetchBoards') 문제상황 페이지 네이션 연습 중 다음과 같은 에러가 떴다. 브라우저상 에러 Server Error TypeError: Cannot read properties of undefined (reading 'fetchBoards') This error happened while generating the page. Any console logs will be displayed in the terminal window. 터미널 에러 error - TypeError: Cannot read properties of undefined (reading 'fetchBoards') undefined에 대한 속성을 읽을 수 없다고 한다. 해결 이유는 페치보드할 시에 값이 없을 수도 있는데 불러오려 그래서인듯 하다. 있을 수도.. 2022. 2. 7.
[eslint error] Expected blank line between class members.eslint(lines-between-class-members) 문제 상황 강의와 똑같이 코드를 쳤는데도 어째서인지 알 수 없는 빨간 줄 에러가 계속 났다. 한줄 한줄 문법을 따져봐도 틀린 것이 없는데 원인을 알 수 없었다. Expected blank line between class members. eslint(lines-between-class-members) 에러 문구는 위과 같았다. 해결 검색해보니 --fix 명령어로 해결 가능한 부분이라고 해서 npx eslint "**/*{ts,tsx}" --fix 로 해결봤다. 뭐가 바뀐건가 봤더니..... eslint에서 개행해달라고 빨간지렁이 냈던 것.................... . . . 에러 나면 일단 에러문구 잘 보고 구글링부터 해보자 ㅎㅎㅎ 2022. 2. 3.