text: import { graphql, useStaticQuery } from "gatsby"
  import React from "react"
  import { Helmet } from "react-helmet"
  
  const query = graphql`
    query {
      site {
        siteMetadata {
          siteTitle: title
          siteDesc: description
          author
          image
          twitterUsername
        }
      }
    }
  `
  
  const SEO = ({ title }) => {
    const { site } = useStaticQuery(query)
    const {
      siteDesc,
      siteTitle,
      image,
      twitterUsername,
    } = site.siteMetadata
    return (
      <Helmet htmlAttributes={{ lang: "en" }} title={`${title} | ${siteTitle}`}>
        <meta name="description" content={siteDesc} />
        <meta name="image" content={image} />
        {/* twitter card */}
        <meta name="twitter:card" content="summary_large_image" />
        <meta name="twitter:creator" content={twitterUsername} />
        <meta name="twitter:title" content={siteTitle} />
        <meta name="twitter:description" content={siteDesc} />
        {/* <meta name="twitter:image" content={`${siteUrl}${image}`} /> */}
      </Helmet>
    )
  }
  
  export default SEO
  