revite/src/components/markdown/Markdown.tsx
2021-07-05 11:25:20 +01:00

17 lines
398 B
TypeScript

import { Suspense, lazy } from "preact/compat";
const Renderer = lazy(() => import("./Renderer"));
export interface MarkdownProps {
content?: string;
disallowBigEmoji?: boolean;
}
export default function Markdown(props: MarkdownProps) {
return (
// @ts-expect-error
<Suspense fallback={props.content}>
<Renderer {...props} />
</Suspense>
);
}