From the course: Software Architecture: Patterns for Developers

Unlock this course with a free trial

Join today to access over 24,600 courses taught by industry experts.

Differences between MVC, MVP, and MVVM

Differences between MVC, MVP, and MVVM

- [Instructor] Now that we know what MVC, MVP and MVVM are, let's take a look at the differences. The goal here isn't to be pedantic or purist, but rather, we want to be able to understand the differences, know the intention of each pattern, and follow its guidelines when we're working in a specific architecture. So here are the differences. First, there's the underlying technical concern of which component catches the user interaction. Is it a view like an MVP and MVVM? Or is it a controller like an MVC? Another difference is the amount of code in the UI, often in a code behind file. In MVP, the view needs to be aware of the presenter, so it can pass on commands and events. In MVC and MVVM, the view could be pure markup or contain only pure UI code. This also reveals a third difference. How aware is the view of the underlying model? In MVC, the view binds to the model. In MVP, it depends on the flavor. In supervising controller, it's okay for the view to know the model. In passive…

Contents