-
Notifications
You must be signed in to change notification settings - Fork 1
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
✨[FEAT] 바텀시트 내 검색기능 구현 #465
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
확인했어요~!! 새로운 거 봐서 신기하다... 그리고 data 바뀔 때 애니메이션도 예쁘당...
self.dataSource = UITableViewDiffableDataSource<Section, MajorInfoModel>(tableView: self.majorTV) { (tableView, indexPath, majorName) -> UITableViewCell? in | ||
guard let cell = tableView.dequeueReusableCell(withIdentifier: MajorTVC.className, for: indexPath) as? MajorTVC else { preconditionFailure() } | ||
|
||
cell.cellType = self.cellType | ||
cell.setData(majorName: majorName) | ||
return cell |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 기존 DataSource 대신 이렇게 사용하는구나`!!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
textField가 변화할때마다 snapshot을 이용해서 데이터소스를 변화시켜주는구나 새로운 코드 알아갑니당~~ 고생했어!
🍎 관련 이슈
closed #460
🍎 변경 사항 및 이유
바텀시트 내 검색기능을 구현했습니다.
🍎 PR Point
UITableViewDiffableDataSource
를 이용해 검색어가 바뀔 때마다 검색결과에 반영될 수 있도록 검색 기능을 구현했습니다.UITableViewDiffableDataSource 공식문서
UITableViewDiffableDataSource
요 친구가UITableViewDataSource
를 대체하기 때문에 기존UITableViewDataSource
extension을 다 삭제해주었습니다 참고해주세요!📸 ScreenShot
Simulator.Screen.Recording.-.iPhone.11.-.2022-09-15.at.20.49.53.mp4