In order to use MDX files with Content Collections, we have to transform the collected content.
We have a special package to simplify this process.
Let's see how we can use it.
First we have to install the package @content-collections/mdx package.
pnpm add @content-collections/mdx
After installing the package, we can use the compileMDX function to compile the content of our document.