Introducing Simplified Navigation and Dialog Handling with XAML Commands #2988
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello Prism,
I hope this message finds you well. I'm thrilled to present a new feature that enhances the navigation and dialog handling process in Prism WPF. This enhancement allows developers to seamlessly manage navigation and dialog operations directly through XAML commands, eliminating the need to manually add handlers in the ViewModel.
Here's a breakdown of the changes I've made:
New Files Added:
CloseDialogCommandParameter: Essential parameters for closing a dialog.
NavigateToViewCommandParameter: Essential parameters for navigating to a view.
ShowDialogCommandParameter: Essential parameters for showing a dialog.
DialogCommands: Commands for dialog operations.
Single paramter
Multi parameters
NavigationCommands: Main commands for navigation.
Single paramter
Multi parameters
Benefits:
Simplifies navigation and dialog operations.
No need to create additional handlers in the ViewModel for common operations.
Enhances code readability and maintainability.
Testing:
I'm open to adding specific tests for this feature. Please guide me on where you would recommend including them.
Future Plans:
If this feature is accepted, I plan to extend the same functionality for MAUI and Xamarin in a modular and standardized way.
I believe this feature will significantly improve the developer experience and streamline common operations. If you have any feedback or suggestions, please let me know. I'm more than willing to address any concerns or make further improvements.
Thank you for your time and consideration. Looking forward to your feedback!
Best regards.