Installation
Usage
Add the component to your email template. Include styles where needed.Props
TheButton component accepts all standard HTML anchor (<a>) element attributes.
Link to be triggered when the button is clicked
Specify the target attribute for the button link
The content of the button
Inline styles for the button. Padding is specially handled to work across all email clients, including Outlook
Styling Example
Implementation Details
TheButton component uses advanced techniques to ensure padding works correctly across all email clients, including Outlook which doesn’t support padding on anchor elements. It uses conditional comments and special MSO properties to achieve consistent rendering.
TypeScript
Email Client Support
This component was tested using the most popular email clients.| Gmail | Apple Mail | Outlook | Yahoo! Mail | HEY | Superhuman |
|---|---|---|---|---|---|
| ✔ | ✔ | ✔ | ✔ | ✔ | ✔ |