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

Missing code which is generated from project template #23696

Closed
johndhunter opened this issue Oct 31, 2021 · 3 comments · Fixed by #23699
Closed

Missing code which is generated from project template #23696

johndhunter opened this issue Oct 31, 2021 · 3 comments · Fixed by #23699
Assignees
Labels
Blazor doc-enhancement Source - Docs.ms Docs Customer feedback via GitHub Issue

Comments

@johndhunter
Copy link
Contributor

App component needs
<FocusOnNavigate RouteData="@routeData" Selector="h1" />
and maybe an explanation (i.e. the tooltip)


Document details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

@dotnet-bot dotnet-bot added Blazor Source - Docs.ms Docs Customer feedback via GitHub Issue labels Oct 31, 2021
@guardrex guardrex self-assigned this Oct 31, 2021
@guardrex
Copy link
Collaborator

guardrex commented Oct 31, 2021

Thanks @johndhunter ... To harden this doc (and in other places), we're going to try not to show code that doesn't apply to the scenario at hand. It's too hard to keep up with the churn otherwise. Thanks for reporting this ... I'll take of care it quickly. Leave this issue open, as it will close automatically when the PR merges.

@johndhunter
Copy link
Contributor Author

Cool but I thought this was the scenario at hand (https://docs.microsoft.com/en-gb/aspnet/core/blazor/security/webassembly/standalone-with-authentication-library?view=aspnetcore-6.0&tabs=visual-studio) - in other words that was the self-same set of instructions I followed and it generated that code (VS Version 17.0.0 Preview 7.0 and 6.0.0-rc.2.21480.10)

@guardrex
Copy link
Collaborator

guardrex commented Oct 31, 2021

I mean that it's not relevant to the coverage of the concepts of the section. FocusOnNavigate is for another purpose/goal, having to do with setting nav focus to the top-level header after navigation. It doesn't bear on the security concepts that the section calls out (in the bullet list).

However, I don't really want to drop all of the code. In these cases, I usually make a strategic use of an ellipsis (...) to cover things that changed across versions but that aren't relevant to the section/example. It does have a downside tho: I mostly favor cut-'n-paste examples so that devs can just take the whole thing ... whatever it is ... the App component in this case ... and drop it into an app (e.g., they might be doing an app upgrade) and it will ✨ Just Work!™ ✨. Obviously, my ellipsis approach isn't suitable for that.

I need to get past the 6.0 release tho and some much needed R&R 🏖️ on the 🎁 holiday break ⛄ before I engage with the whole security node. Use of ellipsis is a reasonable compromise at this time with 6.0 about to release while we're all 🏃 ⛰️⛏️😅. I'll reach this node on #19286 for more work. I'm going to cross-link this discussion to that issue to make sure that I review this when the time comes.

Oh ... and I describe the use of an ellipsis in a general way here as a general approach. I won't know for sure if that's going to work until I look on Monday. If it turns out not to be the best approach, then I'll version the content and show the full 6.0 version of the App component (probably).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Blazor doc-enhancement Source - Docs.ms Docs Customer feedback via GitHub Issue
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants