import React from 'react' ; import { Helmet } from 'react-helmet' ; import { APP_DESCRIPTION , APP_TITLE } from '../../util' ; type MetaProps = JSX . IntrinsicElements [ 'meta' ] ; const DEFAULT_META = [ { name : 'description' , content : APP_DESCRIPTION , } , ] ; export interface SeoProps { meta ? : MetaProps [ ] ; title : string ; } export function Seo ( props ) { const { meta = [ ] , title } = props ; return ( < Helmet htmlAttributes = { { lang : 'en' , } } meta = { [ ... DEFAULT_META , ... meta ] } title = { title } titleTemplate = { `%s | ${ APP_TITLE }` } />); }