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

Page to render razor outside of ASP.Net Core needs additional information or references #34188

Open
dipique opened this issue Nov 20, 2024 · 5 comments

Comments

@dipique
Copy link

dipique commented Nov 20, 2024

Description

The solution described in the article works and is highly valuable.

However, following the steps creates an environment that is highly atypical and difficult to use. It is unclear what limitations are present and how those limitations might be overcome.

At the very least, the article needs a section that includes a (non-exhaustive) list/description of limitations like what you see in Nuget libraries that generate strings from razor pages. Assembly binding? Access to HtmlHelpers? Partial views? Layouts? Raw HTML? Use of @model/@inherit?

It would also be really nice if there was a section that briefly touched on how to deal with limitations that exist. For example, I have wasted hours trying to insert raw HTML from a file into my razor view -- without success. And, of course, because of the atypical environment, it is difficult to find applicable advice. So far, I've concluded that you just can't--but it would be extremely helpful to either have that explicitly called out or have a workaround for these basic operations either linked or included in the article.

Page URL

https://learn.microsoft.com/en-us/aspnet/core/blazor/components/render-components-outside-of-aspnetcore?view=aspnetcore-9.0&preserve-view=true

Content source URL

https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/blazor/components/render-components-outside-of-aspnetcore.md

Document ID

12387a0a-7052-5419-5aae-82879c1d2904

Article author

@guardrex

Related Issues

Copy link
Contributor

🍂🎃🏮 Autumn Skies and Pumpkin Pies! 🥧☕🍂

Stand by! A green dinosaur 🦖 will arrive shortly to assist.

@guardrex
Copy link
Collaborator

Thanks for this feedback, @dipique.

Pinging the bosses! 😄 ... @danroth27 and @mkArtakMSFT ... to assist on triage and probably assign a product unit engineer to provide content, tips, and gotchas 😈 that I can add to the article.

@guardrex
Copy link
Collaborator

UPDATE (11/25): There might be a delay. We're in the Thanksgiving 🦃 holiday season here, so it might take a week or longer to advance this. Stand-by, and we'll get back to this ASAP! 🏃‍♂

@guardrex
Copy link
Collaborator

guardrex commented Dec 5, 2024

UPDATE (12/5) ... I'll still need to discuss the priority of this work with management and get a PU engineer on here to discuss the updates.

BTW ... WRT one of your asks ...

trying to insert raw HTML from a file into my razor view

Did a MarkupString fail to work in that scenario? It's covered here if you didn't see it ...

https://learn.microsoft.com/en-us/aspnet/core/blazor/components/?view=aspnetcore-9.0#raw-html

I mean did you try and place the markup to render in the component with a MarkupString and it failed when using this guidance and ended up just rendering text?

Whatever the case with that, let's keep a list here of remaining items that might result in new coverage for the article ...

a section that includes a (non-exhaustive) list/description of limitations like what you see in Nuget libraries that ...

  • generate strings from razor pages
  • Assembly binding?
  • Access to HtmlHelpers?
  • Partial views?
  • Layouts?
  • Raw HTML?
  • Use of @model/@inherit?

@guardrex
Copy link
Collaborator

guardrex commented Dec 12, 2024

UPDATE (12/12): I just received word back from Steve Sanderson offline: We're going to keep this issue and probably take it on in 2025. Management will consider what to add, and a product unit engineer will provide content. I'll mark it P3 (low priority) for the moment, and I'll upgrade its priority early next year.

@guardrex guardrex moved this from Triage to P3 - Low Priority in Blazor.Docs Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: P3 - Low Priority
Development

No branches or pull requests

2 participants