Head

|

Tips

This component is required VML in outlook compatibility for adding elements such as <style> and meta directly to the document

pnpm
aube
bun
npm
yarn
pnpm add jsx-email

Usage

Add the component to your email template. Include children tags where needed.

import { Head } from 'jsx-email';

const Email = () => {
  return (
    <Head>
      <title>My email title</title>
    </Head>
  );
};

Component Props

export interface HeadProps extends BaseProps<'head'> {
  enableFormatDetection?: boolean;
}
enableFormatDetection?: boolean;

This is used to disable the format-detection meta (will be useful for some very specific use-cases) Default value is false

Tips

This component expresses all of the Common Component Props for ComponentProps<'head'>.