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

<script> tag styling #174

Open
tillkruss opened this issue Nov 20, 2017 · 4 comments
Open

<script> tag styling #174

tillkruss opened this issue Nov 20, 2017 · 4 comments

Comments

@tillkruss
Copy link

We have JSON-LD script tags in our emails and they get a style attribute added to them, which doesn't make sense.

<script type="application/ld+json" style="font-family: Avenir, Helvetica, sans-serif; box-sizing: border-box;">
{
    "@context": "http://schema.org",
    "@type": "EmailMessage",
    "potentialAction": {
        "@type": "ConfirmAction",
        "name": "Approve Expense",
        "handler": {
            "@type": "HttpActionHandler",
            "url": "https://myexpenses.com/approve?expenseId=abc123"
        }
    },
    "description": "Approval request for John\u2019s $10.13 expense for office supplies"
}
            </script>
</body>
</html>
@tijsverkoyen
Copy link
Owner

Could it be that you have a * {}-statement in your css file? Probably a reset-file.
Also, why using ld+json in emails? I don't think there is a mailclient that supports it.

@TerraSkye
Copy link

Gmail does : https://developers.google.com/gmail/markup/

@ultrono
Copy link

ultrono commented Sep 20, 2023

@stof
Copy link
Collaborator

stof commented Sep 20, 2023

without a reproducer, there is nothing we can do.

But I indeed suspect that the answer of @tijsverkoyen is right: having a style rule that matches *, and so applies to this script element as well.

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

5 participants