All files / components MetaData.js

71.42% Statements 5/7
100% Branches 2/2
50% Functions 2/4
71.42% Lines 5/7

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 283x 3x   7x 7x   7x                                          
import React from 'react'
import Head from 'next/head'
 
export default function MetaData(props) {
  const d = props.language === 'en' ? props.data.data_en : props.data.data_fr
 
  return (
    <>
      <Head>
        <title>{d.title}</title>
        <meta charSet="utf-8" />
        <meta name="description" content={d.desc} />
        <meta name="author" content={d.author} />
        <meta name="keywords" content={d.keywords} />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        <link rel="icon" href="/favicon.png" />
      </Head>
    </>
  )
}
 
/* istanbul ignore next */
export async function getStaticProps({ locale }) {
  return {
    props: { locale },
  }
}