Chapter 9. Reusable UI Patterns
In this chapter, we will discuss strategies and patterns for reusing visual assets (that is, text and media resources) in cross platform projects. Furthermore, reusable assets will be iteratively explained from the localization perspective. Finally, some advanced software architectural topics about Model-View-Controller and Model-View-ViewModel patterns will be analyzed and demonstrated. This chapter is divided into the following sections:
- Visual assets
- Localization
- Architectural patterns
Visual assets
We can classify any resource included in the project at compile time and used by the user interface as a visual asset. Visual assets can vary from simple text elements to media items (for example images, animations, videos, and so on) to be used for creating the visual elements of the user interface. Each Xamarin target platform provides different mechanisms to store and dispatch these assets.
On Android and iOS, resources and their localized representations...