• 로그인
  • 장바구니에 상품이 없습니다.

home2 게시판 React 게시판 npm error ERESOLVE unable to resolve dependency tree 에러

npm error ERESOLVE unable to resolve dependency tree 에러

4 글 보임 - 1 에서 4 까지 (총 4 중에서)
  • 글쓴이
  • #133885

    이덕형
    참가자
    불과 몇일전에 react 개발환경 설정했다가. 
    오늘 신규 프로젝트 생성하는데 아래와 같은 에러가 발생하네요 
    
    얼마전 react 버전업 (18 ->19) 하며 나는 오류라는데 
    저 같은 경우에는 프로젝트 생성시 뒤에 --legacy-peer-deps 옵션도 넣어보고 
    npm install --force
    npm install --legacy-peer-deps
    위처럼 해봐도 안되서 
    
    결국 돌아는 가는게 
    > npm install web-vitals
    를 해보니 돌아는 가네요. 
    
    근본적 해결방법은 react 버전업인 것 같지만. 
    저 처럼 빠르게 해결보고 싶으신 분은 위 방법을 추천합니다.
    
    
    ---------------------------------------------------------------------------
    npm error code ERESOLVE
    npm error ERESOLVE unable to resolve dependency tree
    npm error
    npm error While resolving: shop@0.1.0
    npm error Found: react@19.0.0
    npm error node_modules/react
    npm error   react@"^19.0.0" from the root project
    npm error
    npm error Could not resolve dependency:
    npm error peer react@"^18.0.0" from @testing-library/react@13.4.0
    npm error node_modules/@testing-library/react
    npm error   @testing-library/react@"^13.0.0" from the root project
    npm error
    npm error Fix the upstream dependency conflict, or retry
    npm error this command with --force or --legacy-peer-deps
    npm error to accept an incorrect (and potentially broken) dependency resolution.
    npm error
    npm error
    npm error For a full report see:
    npm error C:\Users\RnL\AppData\Local\npm-cache\_logs24-12-12T01_58_57_489Z-eresolve-report.txt
    npm error A complete log of this run can be found in: C:\Users\RnL\AppData\Local\npm-cache\_logs24-12-12T01_58_57_489Z-debug-0.log
    #133887

    codingapple
    키 마스터
    요즘은 npm create vite@latest 로 프로젝트 생성하는게 제일 낫습니다
    #133921

    이덕형
    참가자
    혹시 위 것에 대한 자세한 설명이 가능 하실까요? 
    
    npx create-react-app [프로젝트명] 대신 사용하는 걸까요? 
    아니면 프로젝트를 위처럼 생성한후 추가로 실행하는건가요?
    #133949

    codingapple
    키 마스터
    create react app 대신 사용하면 됩니다
4 글 보임 - 1 에서 4 까지 (총 4 중에서)
  • 답변은 로그인 후 가능합니다.

About

현재 월 700명 신규수강중입니다.

  (09:00~20:00) 빠른 상담은 카톡 플러스친구 코딩애플 (링크)
  admin@codingapple.com
  이용약관
ⓒ Codingapple, 강의 예제, 영상 복제 금지
top

© Codingapple, All rights reserved. 슈퍼로켓 에듀케이션 / 서울특별시 강동구 고덕로 19길 30 / 사업자등록번호 : 212-26-14752 온라인 교육학원업 / 통신판매업신고번호 : 제 2017-서울강동-0002 호 / 개인정보관리자 : 박종흠