I was wondering if I could have multiple post types in a gatsby static site.
On gatsby-config.js I have the following code.
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/content/books`,
name: `books`,
}
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/content/posts`,
name: `posts`,
}
Both the folders have relevant markdown files and I could not find any examples of graphql to retrieve both.
Thanks in advance.
"/(\/content\/posts)/.*\\.md$/"
results inGraphQLError: Syntax Error: Invalid character escape sequence: \..
– Muscle