Markdown referencing markdown with Gatsbyย ย ๐Ÿ“„ย ๐Ÿ”„

In yesterday's unauthorized and rum-fueled treasure hunts in the sharky waters around the Gatsby islands helping Mirjam we looked at how to use markdown for marketing pages.

YouTube Sceengrab

One of the tricks we covered is to reference a markdown file from the front matter of another markdown file.

---
sections:
  - title: About us
    md: ../about.md
---

It gives you access to the fully transformed markdown node through childMarkdownRemark.

query ExampleQuery {
  markdownRemark{
    frontmatter {
      sections {
        title
        md {
          childMarkdownRemark {
            html
          }
        }
      }
    }
  }
}

Kinda neat, right?

ย 
All the best,
Queen Raae

ย 
PS: I am a markdown aficionado, how about you? Would you like more markdown tips and tricks?

Stuck on a reef in the sharky waters around the Gatsby islands?

Book a 1-on-1 Gatsby Call with Queen Raae. Friendly advice you can put into action immediately, guaranteed!

Serious about Gatsby? Sign up for emails sent every weekday to help you get the most out of Gatsby!