Syntax Highlighting Code Blocks using Components with Prism React Renderer and Gatsby MDX

Chris Biscardi
InstructorChris Biscardi

Share this video with your friends

Send Tweet

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.

Tom Byrer
Tom Byrer
~ a year ago

I think now we con use 'optional chaining':

language={
    matches?.groups?.lang
}