Swift flux
-
Upload
sigma-software -
Category
Software
-
view
178 -
download
0
Transcript of Swift flux
@DAlooG
ABOUT ME➤iOS Developer at Sigma Software ➤Enterprise and client applications ➤Team leader ➤Mentor ➤Consultant
2
@DAlooG
APPLE SOLUTION
https://developer.apple.com/library/ios/documentation/General/Conceptual/CocoaEncyclopedia/Model-View-Controller/Model-View-Controller.html#//apple_ref/doc/uid/TP40010810-CH14-SW14
5
@DAlooG
APPLE SOLUTION
https://developer.apple.com/library/ios/documentation/General/Conceptual/DevPedia-CocoaCore/MVC.html
7
@DAlooG
PROBLEMS➤Controller need to rule view and model
layers ➤View receive updates. So order of updates
is important ➤Model receive updates. So order of
updates is important ➤Controller is bloated with responsibilities
8
«
@DAlooG
I say with confidence as a former UIKit author: React's model for the UI layer is vastly better than UIKit's. React Native is a *huge* deal.
https://twitter.com/andy_matuschak/status/560511204867575808
11
«
@DAlooG
One can merge the MVC roles played by an object, making an object, for example, fulfill both the controller and view roles—in which case, it would be called a view controller.
http://apple.co/1U6DPF313
@DAlooG
APPLE SOLUTION
https://developer.apple.com/library/ios/documentation/General/Conceptual/DevPedia-CocoaCore/MVC.html
19
@DAlooG
ACTION / COMMAND➤Representation of increment ➤User actions (tap, gestures, shake) ➤API callbacks ➤Timer events
➤Action is immutable ➤Action is serializable ➤Action is printable
23
@DAlooG
STORE / REDUCER / UPDATE➤Stores data ➤Update data according to actions ➤Notify listeners about data updates
➤Most application logic lives here ➤Covered with Unit Tests ➤Implemented as class
25
@DAlooG
STATE➤Immutable value type ➤Valid most of the times ➤Domain specific
➤Implemented as struct
26
@DAlooG
LINKS➤http://blog.benjamin-encz.de/a-flux-inspired-architecture-
for-ios/ ➤https://developer.apple.com/library/ios/documentation/
General/Conceptual/CocoaEncyclopedia/Model-View-Controller/Model-View-Controller.html#//apple_ref/doc/uid/TP40010810-CH14
➤https://developer.apple.com/library/ios/documentation/General/Conceptual/DevPedia-CocoaCore/MVC.html
➤https://github.com/yonekawa/SwiftFlux ➤https://github.com/ReduxKit/ReduxKit ➤https://github.com/ReSwift/ReSwift