-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Closed
Description
I wired up the contentful source plugin to fetch some blog content, but it's unclear to me how to handle the post body.
I assumed I could just grab the html prop from the childMarkdownRemark field in the body, but the html therein doesn't include <img> tags. Here's an example:
// query
{
allContentfulBlogPostBodyTextNode {
edges {
node {
body
childMarkdownRemark {
html
}
}
}
}
}
// result
{
"data": {
"allContentfulBlogPostBodyTextNode": {
"edges": [
{
"node": {
"body": "Hi this is markdown \n\n[link test](https://www.google.com)\n\n",
"childMarkdownRemark": {
"html": "<p>Hi this is markdown </p>\n<p><a href=\"https://www.google.com\">oh u want imgs here </a></p>\n<p></p>"
}
}
}
]
}
}
}
Is this a bug, or si there another way to fetch the rendered html?
Metadata
Metadata
Assignees
Labels
No labels