Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save rileybathurst/51cdf936bbaf6239c5f6436dc99d6b82 to your computer and use it in GitHub Desktop.
Save rileybathurst/51cdf936bbaf6239c5f6436dc99d6b82 to your computer and use it in GitHub Desktop.
reactmarkdown children
import * as React from "react";
import { graphql } from "gatsby";
import ReactMarkdown from "react-markdown";
const IndexPage = ({ data }) => {
return (
<>
<ReactMarkdown children={service.markdown} />
</>
);
};
export default IndexPage;
export const pageQuery = graphql`
query MyQuery {
allStrapiService {
edges {
node {
markdown
}
}
}
}
`;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment