Quantcast
Channel: ReScript Forum - Latest posts
Viewing all articles
Browse latest Browse all 2592

Static component properties in React

$
0
0

Hello,

I want to use CLI - React Email and I’m wondering how I would write a binding for

export default function Email(props) {
  return (
    <div>
      <a src={props.source}>click here if you want candy 👀</a>
    </div>
  )
}

Email.PreviewProps = {
  source: 'https://www.youtube.com/watch?v=dQw4w9WgXcQ'
}

I can’t quite figure out the Email.PreviewProps part.


Viewing all articles
Browse latest Browse all 2592

Trending Articles