반응형
원인
GitHub Pages는 기본적으로 Jekyll이라는 정적 사이트 생성기를 사용합니다.
그리고 Jekyll은 _next/
, _site/
, _includes/
처럼 밑줄(_)로 시작하는 폴더를 무시합니다.
즉, _next/
폴더가 있어도 서빙되지 않습니다.
해결 방법: .nojekyll
파일 추가
.nojekyll
이라는 빈 파일을 GitHub Pages 루트에 추가하면 Jekyll 처리를 비활성화할 수 있습니다.
touch docs/.nojekyll
git add docs/.nojekyll
git commit -m "fix: add .nojekyll to serve _next static files"
git push origin main
반응형