Recent

Author Topic: How do you seperate data from views in small apps  (Read 1032 times)

Leledumbo

  • Hero Member
  • *****
  • Posts: 8226
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: How do you seperate data from views in small apps
« Reply #15 on: April 14, 2020, 07:37:18 pm »
How do you then bind/update the data to the UI? Do you use special controls or just fire and update after the data is gathered?
It's up to the caller, this is not using data binding (which defeats the OP purpose to separate data from view) at all. Technically if you wish, though, you can implement a callback/event system, where the UI registers its own method to the data layer. But I found this to be a maintenance burden for the team. Manual assignment isn't that cumbersome and is a lot clearer and cleaner, no magic that needs explanation required.

 

TinyPortal © 2005-2018