본문 바로가기
컴퓨터/오류해결

[Vue3] Module not found: Error: Can't resolve '@fullcalendar/daygrid, interaction' (FullCalendar.js)

by 버니케이 2023. 5. 9.
반응형
1. 문제발생
2. 원인찾기
3. 문제해결

 

 

1. 문제발생

작업중인 프로젝트의 

데이터 바인딩 시 calendar 형태로 표현해야된다고 해서

FullCalendar.js vue 버전을 찾아 install 을 했습니다.

 

 

https://fullcalendar.io/docs/vue

 

Vue Component - Docs | FullCalendar

FullCalendar seamlessly integrates with the Vue JavaScript framework. It provides a component that exactly matches the functionality of FullCalendar’s standard API. This package is released under an MIT license, the same license the standard version of F

fullcalendar.io

 

 

사용법대로 페이지를 만들었는데 다음과 같은 오류가 발생했습니다.

Module not found: Error: Can't resolve '@fullcalendar/interaction'
Module not found: Error: Can't resolve '@fullcalendar/daygrid'

 

 


 

 

2. 원인찾기

module not found 여서 install 문법이 잘못되었나 공식 홈페이지에서 확인중

위에 명령어로 설치하면 깔린다고 분명히 써있거든여...? additional 이라면서여

아 추가로 저거 엔터쳐져있는거 굉장히 킹받는데

 npm install --save \  @fullcalendar/core \  @fullcalendar/vue3

이거쓰시면됩니다.

 

 

아무튼

daygrid, interaction 이 플러그인이 잘 안깔린거같아서 package.json 을 확인했습니다.

안깔려있죠?

 


 

 

 

3. 문제해결

 

공식사이트의 github 가 있더라구여

package.json 파일 까봤습니다.

https://github.com/fullcalendar/fullcalendar-examples/blob/main/vue3/package.json

너므한거 아니냐구우....

 

 

 

로컬로 돌아와서

작업중인 package.json - dependencies 에 다음과 같이 추가해줍니다.

"@fullcalendar/daygrid": "^6.1.7",
"@fullcalendar/interaction": "^6.1.7",
"@fullcalendar/timegrid": "^6.1.7",

저는 시간도 출력해줘야될거같아서 time 도 했는데, 필요없으면 안하셔도됩니당

 

 

저장한다음 npm install 해주세용

잘깔리죠??

npm run serve 해줍시당

 

잘뜬당!!!

반응형

댓글