Adding tailwind as css library, build config and fetch posts fix
This commit is contained in:
@@ -3,6 +3,7 @@ import React from 'react'
|
||||
const IndexPage = () => (
|
||||
<div>
|
||||
<h1>Index page</h1>
|
||||
<p>Testing</p>
|
||||
</div>
|
||||
)
|
||||
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
import React, { Component } from 'react';
|
||||
|
||||
class PostDefault extends Component {
|
||||
render() {
|
||||
const { data } = this.props
|
||||
return (
|
||||
<div>
|
||||
<h1>Specific Post - {data.wordpressPost.title}</h1>
|
||||
<div dangerouslySetInnerHTML={{
|
||||
__html: data.wordpressPost.content
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export const query = graphql`
|
||||
query PostDefaultQuery($slug: String!) {
|
||||
wordpressPost(slug: {eq: $slug}) {
|
||||
title
|
||||
slug
|
||||
content
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export default PostDefault;
|
||||
Reference in New Issue
Block a user