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

Seeking clarification on "HTML <body> feature is unsupported" error #432

Open
kdipippo opened this issue May 30, 2024 · 1 comment
Open
Labels
Data bug Did we say something wrong?

Comments

@kdipippo
Copy link

kdipippo commented May 30, 2024

Hello! I've been using the results of this repo in combination with a downstream CLI tool https://github.com/shellscape/doiuse-email that relies on the "API" data to perform linting on some HTML templates.

My main consumers will be OutLook email clients. My email templates are currently structured with:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
  <head>
    <meta content="text/html charset=UTF-8" http-equiv="Content-Type"/>
  </head>
  <body>
    ... email content ...
  </body>
</html>

If I run this against the doiuse-email linter, I get the errors:

- `<body> element` is not supported by `outlook.macos`
- `<body> element` is not supported by `outlook.ios`
- `<body> element` is not supported by `outlook.android`

This correctly reflects the entries in this file:

...where values for these booleans were confirmed by creating emails with this content: https://github.com/hteumeuleu/caniemail/blob/main/tests/html-body.html

I have access to OutLook for MacOS 16.82.1, and I was curious to see what this test validates.

Screenshot of html-body.html in Chrome browser

image

Screenshot of html-body.html in my OutLook Mac 16.82 inbox sent using Python3 smtplib's sendmail() image

Apologies if these are basic questions. But what do these tests mean? Is the fact that the OutLook email screenshot not having a yellow background indicate that color styling can't be applied? What alternative does OutLook need to use in place of <body> or is it just I can't have styling attributes applied to it? I'm also thrown by what the Chrome screenshot shows, but that may be because the test is built for emails-only and not for browser previewing.

@hteumeuleu hteumeuleu added the Data bug Did we say something wrong? label May 30, 2024
@hteumeuleu
Copy link
Owner

Hello! In this exact case, this means the Outlook email clients replace the <body> element by another element (in this case, a <div>). But this makes me realize that the values are not very consistent here as the Not supported values here should probably be more a Partial support (with the first note appended). Would that make more sense?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Data bug Did we say something wrong?
Projects
None yet
Development

No branches or pull requests

2 participants