Replies: 1 comment 1 reply
-
I agree, and that sort of Options based pattern is quite common in several Microsoft libraries as well, especially for we want to be able to add additional options. I think some of the overloads should probably stay and convenience methods and simply call the overload that takes the DialogOptions, but would probably need to review that on a case-by-case basis. |
Beta Was this translation helpful? Give feedback.
1 reply
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
-
I was recently checking out what it would take to add a fullscreen
DialogHost
. With a basic PoC I ended up adding a new parameter to theDialogHost.Show
method. This clutters theShow(..)
methods on theDialogHost
even more.Thoughts on adding a new class which bundles all the parameters the consumer can pass into the
Show()
methods? They have done the same in MudBlazors Dialog.It would remove the method-clutter we currently have, and in my opinion improve discoverability, because you wouldn't have to look through so many method overloads and optional parameters.
The new API could look something like this
New
DialogOptions
class:New
DialogHost.Show
API:If the above ends up being a thing, we should probably mark the current
Show(..)
methods asObsolete
for a few versions.Beta Was this translation helpful? Give feedback.
All reactions