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

Better standalone support #10650

Closed
rmannibucau opened this issue Jul 19, 2024 · 1 comment
Closed

Better standalone support #10650

rmannibucau opened this issue Jul 19, 2024 · 1 comment

Comments

@rmannibucau
Copy link

Hi,

Would be great to enhance the razor standalone support (htmlrenderer) to support more features out of the box like:

  • layout
  • raw string

Currently it is not usable as a html static template engine and requires to use razorlight or razorengine mainly cause of the lack of these features (or you need to reimplement it yourself).

Ideally enhancing the htmlrenderer API to be able to pass a custom view resolver, get a base component which is not componentbase but a templatebase like (with html helper) would be a very good addition IMHO.

@davidwengier
Copy link
Contributor

Thanks for the issue @rmannibucau but I'm afraid I don't have much good news.

HtmlRenderer is a runtime feature so any requests for changes to the API or feature set would need to have an issue opened on https://github.com/dotnet/aspnetcore

Not being able to use raw string literals is an issue for the Razor compiler, which is this repo, and is already tracked by #7084 and currently being worked on.

Unfortunately being able to use the Razor compiler as a standalone static site generator is not currently a goal of this repo. There are some more details about this outlined in #8399.

@davidwengier davidwengier closed this as not planned Won't fix, can't repro, duplicate, stale Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants