Prism is a popular syntax highlighter in the Gatsby ecosystem. Here's how to use the more powerful and flexible component model to enable syntax highlighting in your MDX files using Prism React Renderer.
I think now we con use 'optional chaining':
language={
matches?.groups?.lang
}