Skip to content

pantoken / renderers/react-markdown/src / createInstuiMarkdownComponents

تابع: createInstuiMarkdownComponents()

createInstuiMarkdownComponents(options?): Components

بتا

نقشهٔ کامپوننت react-markdown را برای یک مجموعه از گزینه‌های رندر بسازید.

پارامترها

options?

InstuiMarkdownRenderOptions = {}

InstuiMarkdownRenderOptions.

مقدار بازگشتی

Components

یک نقشهٔ components برای react-markdown که توسط Instructure UI پشتیبانی می‌شود.

نمونه

نقشه را مستقیماً به react-markdown ارسال کنید

tsx
import Markdown from "react-markdown";
import { createInstuiMarkdownComponents } from "@pantoken/react-markdown";

const components = createInstuiMarkdownComponents({ tableCaption: "Grades" });
<Markdown components={components}># Report</Markdown>;