0

I'd like to create a MediaTypeFormatter that handles HTML MIME types, similar to this. The catch is that I don't want (or have) a view/template file: I want to generate the HTML string given just the object (the value) and it's type.

  • If Razor already supports this, please point me to the documentation or an example.
  • If Razor covers only a part of my need, please help me understand the gap that I'd need to fill in.
  • If Razor isn't helpful, I assume reflection is my best bet. If you want to start me off, be my guest.

I feel like I've seen something similar to what I need, but I can't find it at this point. What functionality does Razor have to support my use case?

2
  • I'm confused. You don't want to have a view/template but you want to use Razor, which is a templating language? Commented Mar 29, 2017 at 1:30
  • @DavidG I want a view minus the file. Does that make sense? Commented Mar 29, 2017 at 15:07

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.