A Gatsby theme for creating a material-design blog.
npm install --save gatsby-theme-material-blog
Key | Default value | Description |
---|---|---|
basePath |
/ |
Root url for all blog posts |
contentPath |
content/posts |
Location of blog posts |
// gatsby-config.js
module.exports = {
plugins: [
{
resolve: `gatsby-theme-material-blog`,
options: {
basePath: `/blog`,
},
},
],
}
In addition to the theme options, there are a handful of items you can customize
via the siteMetadata
object in your site's gatsby-config.js
.
This theme assumes that at least the fields present in the code block below are present.
// gatsby-config.js
module.exports = {
siteMetadata: {
// Used for the site title and SEO
title: `My Blog Title`,
// Used to provide alt text for your avatar
author: `My Name`,
// Used for SEO
description: `My site description...`,
// Used for social links in the root footer
social: [
{
name: `GitHub`,
url: `https://github.com/gatsbyjs`,
},
...
],
},
}
In order to get Algolia Search functionality, you need to define the following variables:
GATSBY_ALGOLIA_APP_ID
GATSBY_ALGOLIA_SEARCH_KEY
ALGOLIA_ADMIN_KEY