What is the MVVM pattern, What benefits does MVVM have?

preview_player
Показать описание
Do you really need to learn MVVM to start developing apps with XAML frameworks like .NET MAUI, Uno, Avalonia, WPF, or WinUI 3? I get asked this question all the time and today, I break down what you need to know about MVVM, what it is, what it looks like to code without it, why you should learn and use it, and finally, how to take advantage of MVVM in your app!

Links:

Join this channel to get access to perks:

Chapters:
00:00 - Introduction, hello!
00:35 - What is MVVM?
03:23 - Development without MVVM & Data Binding
10:00 - Adding MVVM & Data Binding (Community Toolkit Edition)
11:25 - Bindable Properties
16:00 - UI Interaction with Commands
20:15 - Wrap-up on MVVM

Follow:

Disclaimer: This channel, videos, and streams are created in my spare time and are a product of me... James Montemagno! They are NOT officially affiliated or endorsed by Microsoft (my employer) in any way. Opinions and views are my own.

My Setup:

#dotnet #mvvm #dotnetmaui #xaml #winui #avalonia #uno xaml data binding uno data binding wpf mvvm
Рекомендации по теме
Комментарии
Автор

You're great, thanks James! One request: maybe some harder examples than first name and last name which are over and over again in your videos about Maui and new MVVM toolkit? I would like to see some more sophisticated example of this amazing tool.

daliangilbert
Автор

You know what James; I just want you to know that You're the BEST!

wenreloz
Автор

You just sold me on why I should be trying out MVVM with a new MAUI app that I'm trying to write. I appreciate the video, and congrats on recently hitting 100k subs!

paperorplastic
Автор

God I love your videos James they just hit right, like 80% of my questions get answered with all your content. Love it love it. Thank you so much man, once I land my job in cross plat development I'll buy you a coffee. Thanks again brother.

rorydaines
Автор

One major benefit of MVVM is that you can just replace one control with another without needing to rewrite a single line in viewmodel as compared to winforms where you would have to rewrite control names and other code in code-behind. For example, you have collection and selected item properties in viewmodel and in view you have a datagrid, so, using the power of mvvm you can replace datagrid with listview, or similar itemscontrol, or you can just bind those properties to any control you want

rzhv
Автор

There's nothing wrong with MVVM at all, it's a great Pattern. Very useful when you want to create a more advanced Application. The only problem I have is the people who get obsessed with no-code behind. They Ignore the Power of the View Layer, and limited their application.

albertmpro
Автор

The best video on databinding out there. Thank you!

nathanrika
Автор

Thank you very much, This explanation of MVVM is relatively concise.

曼巴-zt
Автор

Thanks James, Just what I needed. This was a great example and demonstration. I would appreciate more content/examples along this line. Thank you. :)

brucefox
Автор

I love the way you explain everything. You are a natural teacher lol

A__Singh__
Автор

Thanks James! The first time in years I get to grasp MVVM concept and from now on I'll adopt it to all my Xamarin projects!

manosgeorgoudakis
Автор

Hi James

Thanks for the video. I think you forgot to cover the "M" in M-V-VM. Maybe you could do another video explaining the "M" in more details and what goes into the model and what goes into the viewmodel - fat viewmodel vs fat model and so on.

jabak
Автор

Realy nice guide of how it works, thanks

rockthomas
Автор

Been an MVVM user since Windows Phone! MVVM Simple and fast!

codetayo
Автор

Damn dude! Thank you! I know mvvm, but this community toolkit is really nice man! :)) Thanks!!!!

florianb.
Автор

Lots of people: "Patterns and templates and modular reusability etc is good stuff. We should do that."

Whoever came up with the MVVM nonsense: "Ok, here's MVVM. It's a pattern. It kind of has some of that modular reusability stuff, sort of, a little bit, if you squint at it sideways from a distance."

Lots of people: "You realise you're still modifying styles and components in about 50 different files, right?"

The MVVM supporters: "Don't mention the shortcomings and mistakes! MVVM is AWESOME!"

FatheringLessons
Автор

Duuuude.. you are the best!!! Thank you sooo much for all the love and info

aqualek
Автор

James you are the man, please continue.

parko
Автор

I felt that Jesús speak to me about MVVM. Thanks, James, for yours excellent videos. Great Look

Автор

This is very well explained, but I am still not sold on the MVVM. It completely fails the KISS principle - it adds a ton of complexity and is basically requiring yet another language with its own syntax. It seems to even make code indexing and searching more complicated because things are not named the same across classes. I am sure this is very useful for high-scale projects, but other than that it seems like a development nightmare.

elimgarak