Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0b282e8
commit 3f71280
Showing
4 changed files
with
238 additions
and
6 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,15 @@ | ||
module.exports = { | ||
siteMetadata: { | ||
title: 'Gatsby Default Starter', | ||
title: 'Gatsby Drupal Starter', | ||
}, | ||
plugins: ['gatsby-plugin-react-helmet'], | ||
plugins: [ | ||
'gatsby-plugin-react-helmet', | ||
{ | ||
resolve: `gatsby-source-drupal`, | ||
options: { | ||
baseUrl: `https://live-contentacms.pantheonsite.io/`, | ||
apiBase: `api`, | ||
}, | ||
}, | ||
], | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,29 @@ | ||
import React from 'react' | ||
import Link from 'gatsby-link' | ||
|
||
const IndexPage = () => ( | ||
const IndexPage = ({ data }) => ( | ||
<div> | ||
<h1>Hi people</h1> | ||
<p>Welcome to your new Gatsby site.</p> | ||
<p>Now go build something great.</p> | ||
<Link to="/page-2/">Go to page 2</Link> | ||
<p>Welcome to your new Gatsby site that is getting data from Drupal.</p> | ||
<p> | ||
The list of recipe titles below is coming from a Contenta CMS site on | ||
Patheon. | ||
</p> | ||
{data.allRecipes.edges.map(recipe => <div>{recipe.node.title}</div>)} | ||
<Link to="/page-2/">Go to see another page</Link> | ||
</div> | ||
) | ||
|
||
export default IndexPage | ||
|
||
export const query = graphql` | ||
query IndexPageQuery { | ||
allRecipes { | ||
edges { | ||
node { | ||
title | ||
} | ||
} | ||
} | ||
} | ||
` |