reducer1 [react] redux reducer 를 작성할 때 switch 에 default 를 빼먹는다면... / The slice reducer for key "letter" returned undefined during initialization. 에러 상황 reducer 를 작성하고 실행했는데, 아래와 같은 에러가 발생했다. The slice reducer for key "letter" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined. "letter" 키에 대한 slice reducer가 초기화 중에 undefined를 반환했.. 2024. 2. 2. 이전 1 다음