Merge pull request #130 from jackbravo/master

Use siteTitle variable instead of hardcoding the title
This commit is contained in:
Joaquin Bravo 2018-11-08 16:32:57 -06:00 committed by GitHub
commit 7f89fb3084
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View file

@ -5,7 +5,7 @@ import { rhythm, scale } from '../utils/typography'
class Layout extends React.Component {
render() {
const { location, children } = this.props
const { location, title, children } = this.props
const rootPath = `${__PATH_PREFIX__}/`
let header
@ -26,7 +26,7 @@ class Layout extends React.Component {
}}
to={'/'}
>
Gatsby Starter Blog
{title}
</Link>
</h1>
)
@ -47,7 +47,7 @@ class Layout extends React.Component {
}}
to={'/'}
>
Gatsby Starter Blog
{title}
</Link>
</h3>
)

View file

@ -17,7 +17,7 @@ class BlogIndex extends React.Component {
const posts = get(this, 'props.data.allMarkdownRemark.edges')
return (
<Layout location={this.props.location}>
<Layout location={this.props.location} title={siteTitle}>
<Helmet
htmlAttributes={{ lang: 'en' }}
meta={[{ name: 'description', content: siteDescription }]}

View file

@ -15,7 +15,7 @@ class BlogPostTemplate extends React.Component {
const { previous, next } = this.props.pageContext
return (
<Layout location={this.props.location}>
<Layout location={this.props.location} title={siteTitle}>
<Helmet
htmlAttributes={{ lang: 'en' }}
meta={[{ name: 'description', content: siteDescription }]}