I have an application with an Emails project, which exposes a class to compile an email template using IRazorViewEngine, and send it.
However, this is used in several different projects, and by default RazorViewEngine seems to only look in the Views folder for the Web project in question. This means I have to duplicate the same views across projects.
I've looked at extending the RazorViewEngine to modify where it looks for views, but every example changes which folder in the project it looks in, not which project, and from a quick look at the RazorViewEngine source it explicitly expects application-local paths (i.e. starting with "~" or "/"), thwarting my naive attempt to use an absolute path or one beginning with "../" .
Is there a way to make sure that RazorViewEngine (or a subclass) checks a specific (non-dynamic) project, as opposed to the Web Project calling it?
The application is using .Net Core 1.1, which RazorEngine doesn't seem to support