MVVM
-
MVC, MVVMProgramming 2020. 6. 26. 22:21
MVC(Model View Controller) controller 가 입력과 출력을 모두 컨트롤. 컨트롤러에게 많은 역할이 주어졌었음. View(UIView) : 화면에 보여줄 부분 담당 controller(UIViewController) : 사용자 Input, 처리로직, 화면에 뿌리는것도 컨트롤러가 담당 Model : 데이터 담당 // list에서 데이터를 삭제 하는 작업을 할때 //1. 뷰 데이터에서 해당 데이터 삭제 self.productList.remove(at: indexPath.section) // 2. UI update self.productListTableView.deleteSections(IndexSet(integer: indexPath.section), with: .automatic)..