You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using FluentEmail which has a dependency on RazorLight.
If my email template contains media css queries within style tags I get this exception:
RazorLight.Compilation.TemplateCompilationException: 'Failed to compile generated Razor template: The name 'media' does not exist in the current context
Steps to reproduce the behavior:
Add FluentEmail nuget package.
Add RazorLight package (v .2.3.1)
Use an html template that includes a media query:
I'm using FluentEmail which has a dependency on RazorLight.
If my email template contains media css queries within style tags I get this exception:
RazorLight.Compilation.TemplateCompilationException: 'Failed to compile generated Razor template: The name 'media' does not exist in the current context
Steps to reproduce the behavior:
Add FluentEmail nuget package.
Add RazorLight package (v .2.3.1)
Use an html template that includes a media query:
@@media only screen and (max-width: 479px) { table[class="wrapper"], tr[class="wrapper"], td[class="wrapper"] { width: 100% !important; max-width: 480px !important; min-width: 320px !important; } }
Call
IFluentEmail.UsingTemplate(template, model, true)
Expected behavior
Using a media query (obviously escaped, i.e.
@@media
should not raise an exception.Setup
The text was updated successfully, but these errors were encountered: