Building a Portfolio and Blog with NextJs and Contentful

This is a heading

Smaller Heading

{ function Post(props: PostProps) { const { blogPost: { content, title } } = props return ( <DefaultLayout> <Heading>{title}</Heading> <ReactMarkdown children={content} components={{ code({node, inline, className, children, ...props}) { const match = /language-(\w+)/.exec(className || '') return !inline && match ? ( <SyntaxHighlighter {...props} style={dark} language={match[1]} PreTag="div" > {String(children).replace(/\n$/, '')} </SyntaxHighlighter> ) : ( <code {...props} className={className}> {children} </code> ) } }} /> </DefaultLayout> ) } }