Skip to content

Container

Horizontally center child components and content

Install

Install the component from your command line

Terminal window
pnpm add jsx-email

Usage

ContainerExample.jsx
import { Button, Container } from 'jsx-email';
const Email = () => {
return (
<Container>
<Button
width={200}
height={40}
href="https://example.com"
>
Click me
</Button>
</Container>
);
};

Props

Optional Props

disableDefaultStyle

disableDefaultStyle?: boolean;

When true, removes default styles. Useful when using Tailwind or custom classes.

Additional Props

This component expresses all of the Common Component Props for ComponentProps<'table'> except for:

  • cellPadding
  • cellSpacing