Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Refactor] 번들 크기 개선 - 3 #432

Merged
merged 4 commits into from
Aug 30, 2024
Merged

Conversation

eonseok-jeon
Copy link
Member

@eonseok-jeon eonseok-jeon commented Aug 24, 2024

Related Issue : Closes #431


🧑‍🎤 Summary

  • manual chunk를 통한 chunk 분리
  • lazy loading 적용
  • build 속도 개선

🧑‍🎤 Screenshot


스크린샷 2024-08-25 오전 1 51 23

후 (번들 크기 개선 1, 2, 3이 통합된 결과예요)
스크린샷 2024-08-25 오전 1 51 43

build 속도를 6.11s 에서 4.99s로 1s 정도 개선할 수 있었습니다 :)

🧑‍🎤 Comment

😈 manual chunk를 통한 chunk 분리

경고창에 manual chunk를 이용하라고 추천해줘서 바로 적용해줬어요
모든 chunk를 로드할 필요 없이 필요한 chunk만 필요한 곳에서 사용하자는 개념이에요

firebase는 지원서 페이지의 파일 input에서만 사용되기에 다른 페이지에선 쓸 일이 없어요
그래서 firebase를 별도의 chunk로 분리해줬답니다

😈 lazy loading 적용

manual chunk와 비슷한 개념인데요 잘 아실거라고 생각들어요
dialog와 error page, nomore page는 특정 상황에서만 필요하기에 첫 페이지 로딩 때는 필요가 없어요
그래서 lazy loading 적용 시켜줬어요
추가로 하나의 페이지에 접속했을 때 다른 페이지는 필요하지 않으므로
router에서 각 페이지에 대한 lazy loading도 적용시켜줬어요

@eonseok-jeon eonseok-jeon linked an issue Aug 24, 2024 that may be closed by this pull request
Copy link

height bot commented Aug 24, 2024

Link Height tasks by mentioning a task ID in the pull request title or commit messages, or description and comments with the keyword link (e.g. "Link T-123").

💡Tip: You can also use "Close T-X" to automatically close a task when the pull request is merged.

@auto-assign auto-assign bot requested a review from lydiacho August 24, 2024 17:04
@eonseok-jeon eonseok-jeon marked this pull request as draft August 24, 2024 17:45
@eonseok-jeon eonseok-jeon changed the base branch from develop to refactor/#431_bundle-size-2 August 24, 2024 17:55
@eonseok-jeon eonseok-jeon marked this pull request as ready for review August 24, 2024 17:55
@eonseok-jeon eonseok-jeon changed the title [Refactor] 번들 크기 개선 [Refactor] 번들 크기 개선 - 3 Aug 24, 2024
@eonseok-jeon eonseok-jeon changed the title [Refactor] 번들 크기 개선 - 3 [Refactor] 번들 크기 개선 - 1 Aug 24, 2024
@eonseok-jeon eonseok-jeon changed the title [Refactor] 번들 크기 개선 - 1 [Refactor] 번들 크기 개선 - 3 Aug 24, 2024
Copy link
Member

@lydiacho lydiacho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

build돌려서 code splitting 잘 되는거 모두 확인했습니다
firebase 청크 분리한 것도 아주 유의미한 것 같아요

고생하셨습니다!! 🚀🚀🚀🚀

Base automatically changed from refactor/#431_bundle-size-2 to develop August 30, 2024 01:06
@eonseok-jeon eonseok-jeon merged commit 0a48579 into develop Aug 30, 2024
@eonseok-jeon eonseok-jeon deleted the refactor/#431_bundle-size branch August 30, 2024 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Refactor] 번들 크기 개선
2 participants