IOS data binding

以下資料皆來自[Ref 1],這裡僅作個人筆記整理:

Data Binding is simply the process that establishes a connection between the app UI (View Controller) and the data (Not Model, But View Model) it displays.

There are different ways of data binding:

Technique 1: Observables
Technique 2: Event Bus / Notification Center
Technique 3: FRP Technique (ReactiveCocoa / RxSwift):
Technique 4: Combine


  • Sample code can be found in [Ref 1]
  • Almost all techniques for data binding use the Publisher-Subscriber pattern.


1) Data Binding in MVVM on iOS:

2) ReactiveCocoa vs RxSwift: