Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Builder .OnStart should allow for any dependency to be resolved #15

Closed
BurkusCat opened this issue Oct 3, 2023 · 0 comments · Fixed by #25
Closed

[Feature] Builder .OnStart should allow for any dependency to be resolved #15

BurkusCat opened this issue Oct 3, 2023 · 0 comments · Fixed by #25
Labels
enhancement New feature or request
Milestone

Comments

@BurkusCat
Copy link
Owner

Is your feature request related to a problem? Please describe.
The current builder .OnStart method allows you to use INavigationService to choose your startup page. You can use ServiceResolver to resolve a service to do more complicated logic but this makes your code less testable.

Describe the solution you'd like
A new overload for .OnStart that allows IServiceProvider to be provided.

Describe alternatives you've considered
ServiceResolver can be used but it is not as test friendly.

Proposed APIs
If possible, try to propose how the API might look. For example:

// BurkusMvvmBuilderExtensions
public static BurkusMvvmBuilder OnStart(this BurkusMvvmBuilder builder, Func<INavigationService, IServiceProvider, Task> onStartFunc)

Additional context
N/A

@BurkusCat BurkusCat added the enhancement New feature or request label Oct 3, 2023
@BurkusCat BurkusCat linked a pull request Oct 12, 2023 that will close this issue
@BurkusCat BurkusCat added this to the MVP milestone Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant