feat: set up basic typography system for Markdown content

This commit is contained in:
Jean-Philippe Sirois
2019-07-29 14:11:56 -04:00
parent 5515ee2172
commit f4384afdca
3 changed files with 92 additions and 1 deletions
+22
View File
@@ -0,0 +1,22 @@
import React from "react"
import * as SC from "./styles"
interface MarkdownProps {
content: string
}
/*
This component is used as a wrapper around Markdown generated content,
mainly to provide styles to the html generated.
*/
export function Markdown({
content,
...restProps
}: MarkdownProps): JSX.Element {
return (
<SC.MarkdownWrapper
dangerouslySetInnerHTML={{ __html: content }}
{...restProps}
/>
)
}