Repository navigation
HomeTab의 View 구성 요소와 렌더링 입력을 분리한다 - #942
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔗 연관된 이슈
🎯 의도
계산 프로퍼티로 구성한 내부 View는 그 안에서 읽은 상태가 바뀌면 부모 View의 body 전체가 다시 평가되는 구조
상태 변화로 재평가가 필요한 영역만 별도 View로 분리하고, 해당 상태를 부모가 아닌 분리한 View의 body에서 읽도록 구성하여 부모 body의 재평가 범위를 줄이는 것
📝 작업 내용
📌 요약
HomeView에서 상태를 읽는 영역을 같은 파일의 private View로 분리SearchView에서searchQuery를 읽는 조건을SearchResults로 이동🔍 상세
HomeViewstore를 전달받는 private View로 분리HomeTodoSection:preferences,isPreferencesLoading,isTodoCategoryExpandedHomeCreateButton:isNetworkConnectedHomeDevelopmentSummary,HomeDevelopmentGoals: 개발 목표 상태HomeContentPicker:preferences,isPreferencesLoadingHomeTodoCategoryLink,HomeContentPickerLabelsend만 호출하는 편집 버튼은 분리하지 않고 유지HomeView의 body는 feature 상태를 읽지 않는 구조SearchViewstore.searchQuery로 결과 노출을 판단하던 조건을SearchResults내부로 이동SearchField,SearchResults,RecentSearchQuries의 상태 읽기 구조는 유지📸 영상 / 이미지 (Optional)
Instruments 측정 (View Body)
View Body (Legacy), 변경 전후 각 5회 교차 측정 후 중앙값 비교, 괄호는 5회 측정 범위홈 화면 (카테고리 펼치기 ↔ 접기 10회)
HomeViewHomeTodoSectionHomeCreateButtonHomeDevelopmentSummaryHomeDevelopmentGoalsHomeTodoCategoryLinkHomeViewbody 평가 횟수가 47회에서 22회로 감소HomeContentPicker,HomeContentPickerLabel은 시나리오에서 평가 기록 없음검색 화면 (검색 열기 ↔ 닫기 10회)
SearchViewSearchResultsSearchFieldRecentSearchQuriesSearchResults를 만들지 않았고 변경 후에는 항상 만들어 평가