-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Blazor API Review: IUriHelper #12425
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
Conversation
c8b2caf
to
9250334
Compare
src/Components/Blazor/Blazor/test/WebAssemblyNavigationManagerTest.cs
Outdated
Show resolved
Hide resolved
src/Components/Blazor/Blazor/src/Services/WebAssemblyNavigationManager.cs
Show resolved
Hide resolved
src/Components/Blazor/Blazor/src/Services/WebAssemblyNavigationManager.cs
Outdated
Show resolved
Hide resolved
src/Components/Components/src/Routing/IHostEnvironmentNavigationManager.cs
Show resolved
Hide resolved
This looks like a lot of good improvements to me. I particularly like the new name and the fact that things are properties instead of |
src/Components/Components/ref/Microsoft.AspNetCore.Components.netstandard2.0.cs
Show resolved
Hide resolved
src/Components/Blazor/Blazor/src/Services/WebAssemblyNavigationManager.cs
Show resolved
Hide resolved
src/Components/Components/ref/Microsoft.AspNetCore.Components.netstandard2.0.cs
Show resolved
Hide resolved
2ae5427
to
cf5f4dd
Compare
cf5f4dd
to
a26d098
Compare
Because of JS interop. I'm planning to fix it. |
a26d098
to
da83ed2
Compare
Ready for another look @SteveSandersonMS @javiercn - I rebased this on top of my other PR so depending on when you look you might need to skip that commit. |
da83ed2
to
6f82d07
Compare
bb97565
to
529494b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
I would have hope that we figured out something for all the shared initializations we need to do in this area, because I think we keep piling up those things in circuithost, but I recognize that that is orthogonal to this PR and we might get to do it if we have time.
The reason I mention this is because every time we have a concept like routing, auth, etc we end up having to add new public API for it.
Cool idea but I think it's really unlikely we'll be able to make this better. However, I think the concept count will be limited for 3-4 in this area. |
- Remove IUriHelper interface - Rename to NavigationManager - Remove all traces of old naming There's no functional or design change in this commit - just removing all traces of the old name. The next few iterations will try to improve the design.
Making Initialize protected causes problems because right now the server-side code needs to deal with one of two different implementations, hence an exchange type is used. I followed the same pattern that was used for auth for symmetry but I have some *cool* thoughts. - We can remove this when we remove stateful prerendering - I have another idea to banish this pattern to the land of wind and ghosts If this ends up sticking around longer than a week in the code, lets discuss other ideas and try to improve the pattern.
Co-Authored-By: campersau <buchholz.bastian@googlemail.com>
529494b
to
2caaa0e
Compare
See: #12397
The last commit is me just doing a bunch of random simplication and clean-up. Let's dicuss anything you don't like about it. I don't have my heart set on doing all of these things, I just had some spare time.