1
0
mirror of https://github.com/jbranchaud/til synced 2026-01-05 08:08:02 +00:00

Add Allow md As An Extension With gatsby-mdx as a react til

This commit is contained in:
jbranchaud
2018-10-27 11:00:18 -05:00
parent a20e287e2e
commit 456dbce841
2 changed files with 23 additions and 1 deletions

View File

@@ -0,0 +1,21 @@
# Allow md As An Extension With gatsby-mdx
The [gatsby-mdx](https://github.com/ChristopherBiscardi/gatsby-mdx) plugin
allows you to create pages in a Gatsby project using `.mdx` files. If you
prefer the `.md` extension on your markdown files, then you can adjust the
plugin options to allow that.
```json
// gatsby-config.js
plugins: [
{
resolve: `gatsby-mdx`,
options: {
extensions: [".mdx", ".md"]
}
}
]
```
This tells `gatsby-mdx` to recognize both `.mdx` and `.md` extensions when
processing files.