Created
February 20, 2019 23:59
-
-
Save geotrev/57a93f4e1f3c7f48c7d75ce0cb5284f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react" | |
import { Helmet } from "react-helmet" | |
import PropTypes from "prop-types" | |
export default function SetMeta({ title, description }) => ( | |
<Helmet titleTemplate="My Site | %s"> | |
<title itemProp="name" lang="en">{title}</title> | |
<meta name="description" content={description} /> | |
</Helmet> | |
) | |
SetMeta.propTypes = { | |
title: PropTypes.string.isRequired, | |
description: PropTypes.string.isRequired, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment