// @flow
import React from 'react'

import type { Node } from 'react'

type Props = {
  children: Node,
  className: string,
  href: string,
  style?: Object
}

export const ExternalLink = ({ href, className, children, style }: Props) => (
  <a
    href={href}
    target="_blank"
    rel="noopener noreferrer"
    className={className}
    style={style}
  >
    {children}
  </a>
)

export default ExternalLink
