인프런 영문 브랜드 로고
인프런 영문 브랜드 로고

인프런 커뮤니티 질문&답변

진현서님의 프로필 이미지
진현서

작성한 질문수

Slack 클론 코딩[실시간 채팅 with React]

사용자 초대 모달 만들기

no overload matches this call

작성

·

237

0

TS2769: No overload matches this call.

  Overload 1 of 3, '(loadFn: (props: unknown) => Promise<DefaultComponent<unknown>>, options?: OptionsWithoutResolver<unknown> | undefined): LoadableComponent<unknown>', gave the following error.

    Type 'Promise<typeof import("/workspace/chatting_app/alecture/layouts/Workspace/index")>' is not assignable to type 'Promise<DefaultComponent<unknown>>'.

      Type 'typeof import("/workspace/chatting_app/alecture/layouts/Workspace/index")' is not assignable to type 'DefaultComponent<unknown>'.

        Property 'default' is missing in type 'typeof import("/workspace/chatting_app/alecture/layouts/Workspace/index")' but required in type 'DefaultImportedComponent<unknown>'.

  Overload 2 of 3, '(loadFn: (props: any) => Promise<ComponentClass<any, any> | { default: ComponentClass<any, any>; }>, options?: Options<any, ComponentClass<any, any>> | undefined): LoadableClassComponent<...>', g

ave the following error.

      Type 'typeof import("/workspace/chatting_app/alecture/layouts/Workspace/index")' is not assignable to type 'ComponentClass<any, any> | { default: ComponentClass<any, any>; }'.

        Property 'default' is missing in type 'typeof import("/workspace/chatting_app/alecture/layouts/Workspace/index")' but required in type '{ default: ComponentClass<any, any>; }'.

 const LogIn = loadable(() => import('@pages/LogIn'));

 const SignUp = loadable(() => import('@pages/SignUp'));

 const Workspace = loadable(() => import('@layouts/Workspace'));

제로초님 아무리 노력해도 어디가 문제인지 못찾겠습니다 어디서부터 어떻게 해결해야 할까요??

답변 1

1

제로초(조현영)님의 프로필 이미지
제로초(조현영)
지식공유자

Workspace/index.tsx에서 export default 안 하신 것 아닌가요?

진현서님의 프로필 이미지
진현서
질문자

구름ide자체 문제인 것 같습니다 감사합니다!

진현서님의 프로필 이미지
진현서

작성한 질문수

질문하기