d0a3d8d144
commit 56c1608deaf1921a80dc71bcbd107e772dd656f4 Author: Omar López <zomars@me.com> Date: Wed Dec 21 19:26:04 2022 -0700 Update link.ts commit eab43d833515cabc7acf2f973c2d2837ac1a0332 Author: zomars <zomars@me.com> Date: Wed Dec 21 19:03:02 2022 -0700 Prevents 500 on TRPC error commit 3a6970d5e5fab54136b379e1b2ccd7acf515a809 Author: zomars <zomars@me.com> Date: Wed Dec 21 18:15:26 2022 -0700 Encoding fixes |
||
---|---|---|
.. | ||
src | ||
templates | ||
README.md | ||
email-manager.ts | ||
index.ts | ||
package.json | ||
tailwind.config.js | ||
tsconfig.json |
README.md
JSX email templates
components
Holds reusable patternstemplates
A template equals a type of email sent
Usage
import { renderEmail } from "@calcom/emails";
renderEmail("TeamInviteEmail", */{
language: t,
from: "teampro@example.com",
to: "pro@example.com",
teamName: "Team Pro",
joinLink: "https://cal.com",
});
The first argument is the template name as defined inside templates/index.ts
. The second argument are the template props.
Development
You can use an API endpoint to preview the email HTML, there's already one on /apps/web/pages/api/email.ts
feel free to change the template to the one you're currently working on.