diff --git a/snippets/Mailto.md b/snippets/Mailto.md index 5a0a77932..e776c1bcb 100644 --- a/snippets/Mailto.md +++ b/snippets/Mailto.md @@ -6,14 +6,14 @@ tags: components,beginner Renders a link formatted to send an email. - Destructure the component's props, use `email`, `subject` and `body` to create a `` element with an appropriate `href` attribute. -- Render the link with `props.children` as its content. +- Render the link with `children` as its content. ```jsx -function Mailto({ email, subject, body, ...props }) { +const Mailto = ({ email, subject, body, children }) => { return ( - {props.children} + {children} ); -} +}; ``` ```jsx