Book Image

PhoneGap for Enterprise

By : Kerri Shotts
Book Image

PhoneGap for Enterprise

By: Kerri Shotts

Overview of this book

Table of Contents (16 chapters)
PhoneGap for Enterprise
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Common patterns


There are several patterns that you should be familiar with before we cover some of the popular platforms. We'll cover the Model-View-Controller (MVC) architecture pattern, templates, routing, and data binding.

MVC (Model-View-Controller)

MVC or Model-View-Controller is an architecture pattern that simplifies UI development. In it are many different variations, such as MVP (Model-View-Presenter) and MVVM (Model-View-View-Model), but the fundamental architecture is about the separation of concerns for easier implementation and maintainability. A simplified example of MVC is shown in the following figure:

Model is responsible for storing and manipulating the data for the application: think of these as representations of the things in your app. For example, tasks, people, tickets, and so on.

View is responsible for displaying that data to the user. These are the physical representations of the things in your app, for example, a view might render a photograph (the view) of a person...