Starting with MVVM using MVVM Community Toolkit, failing to understand it [closed]
First of all, please excuse me for any grammatical/formatting error as I'm not used to directly ask on forums and english is not my first language. Not really a question but more a "General Help Needed", anyway. For context I've started programming "for real" in 2022~ when I started working. That means I've started the journey with WinForms and Visual Basics but "taught" by someone who thinks he's still using VB6 or worse Quick Basic (By that time I had only had some previous experience in school using C with Arduino and a few PICs). Given the growing complexity of the programs I have to write in the last period (both for work and personal) I was trying to move my focus to WPF/Avalonia and C#. And that brings us to MVVM, after a few months I feel I've kind of got the basics figured out but I've yet to make anything meaningful but a few examples so that I don't forget what I learned. By basics I mean binding to Properties and Commands mostly using the MVVM Community Toolkit. I think I'm struggling so much mostly because I don't have access to anyone who can explain those to me nor updated beginner-friendly resources (I'm mostly finding years old or over complicated guides or I end up having to ask to chatbots and having to spend hours to check if the answers make sense) Right now, I'm stuck at trying to re-make a simple multi window application I've made when I started (basically main + settings window) as I can't figure out how I should share data between the two. I usually would have had a public static class (vb public module) or directly instantiated the settings window inside the main window but for what I understand is bad practice and goes against the whole MVVM principles. I've seen there are thing like messangers and dependency injections but I have no clue on how those work. So, the actual question is: Can anyone at least point me in the right direction and/or leave a few examples/resources that can help me understand how to properly use the MVVM pattern? (If possible not just "do that" type of example but something that tells me why I should/shouldn't do "that", my goal is to understand what I'm doing and learn it to be able to reproduce and adapt it the next time I need to, not just receiving a solution)
First of all, please excuse me for any grammatical/formatting error as I'm not used to directly ask on forums and english is not my first language.
Not really a question but more a "General Help Needed", anyway.
For context I've started programming "for real" in 2022~ when I started working.
That means I've started the journey with WinForms and Visual Basics but "taught" by someone who thinks he's still using VB6 or worse Quick Basic (By that time I had only had some previous experience in school using C with Arduino and a few PICs).
Given the growing complexity of the programs I have to write in the last period (both for work and personal) I was trying to move my focus to WPF/Avalonia and C#.
And that brings us to MVVM, after a few months I feel I've kind of got the basics figured out but I've yet to make anything meaningful but a few examples so that I don't forget what I learned.
By basics I mean binding to Properties and Commands mostly using the MVVM Community Toolkit.
I think I'm struggling so much mostly because I don't have access to anyone who can explain those to me nor updated beginner-friendly resources (I'm mostly finding years old or over complicated guides or I end up having to ask to chatbots and having to spend hours to check if the answers make sense)
Right now, I'm stuck at trying to re-make a simple multi window application I've made when I started (basically main + settings window) as I can't figure out how I should share data between the two.
I usually would have had a public static class (vb public module) or directly instantiated the settings window inside the main window but for what I understand is bad practice and goes against the whole MVVM principles.
I've seen there are thing like messangers and dependency injections but I have no clue on how those work.
So, the actual question is:
Can anyone at least point me in the right direction and/or leave a few examples/resources that can help me understand how to properly use the MVVM pattern? (If possible not just "do that" type of example but something that tells me why I should/shouldn't do "that", my goal is to understand what I'm doing and learn it to be able to reproduce and adapt it the next time I need to, not just receiving a solution)