How to Add Documents
This is the process of how you should add new pages and documents to this website.
MDX Format
We will be using the .mdx format to create our documents. MDX is a format that lets you seamlessly use JSX in your Markdown documents. You can import components, like interactive charts or notifs, and export metadata. This makes writing long-form content with components a blast 🚀
Adding Document Pages
Create a .mdx file in
src/pages
Add the required frontmatter at the top of the page. You will need this if you want it to display in the sidebar.
// Your .mdx page --- title: How to Add Documents ---
You have the option to create React Components and add them to the MDX file. React components for pages should be located in src/components
Updating the sidebar
After you've added a page, you may want to add it to the sidebar. At src/sidebar.js
, you'll find the layout for
the main site navigation and sidebar. You can add your page where it makes sense in the site's information architecture.
There are examples in the sidebar file to follow. You'll need to add an object with name
and href
properties
for regular links and you can also create nested sections by leaving out href
and adding an items
array to objects.
GraphQl Sample Reference
https://www.gatsbyjs.org/docs/graphql-reference/