DiffSourceToggleWrapper variable

A wrapper element for the toolbar contents that lets the user toggle between rich text, diff and source mode. Put the rich text toolbar contents as children of this component. For this component to work, you must include the diffSourcePlugin.

Signature:

DiffSourceToggleWrapper: React.FC<{
    children: React.ReactNode;
}>

Example

 <MDXEditor markdown='Hello world'
   plugins={[toolbarPlugin({
     toolbarContents: () => ( <> <DiffSourceToggleWrapper><UndoRedo /><BoldItalicUnderlineToggles /></DiffSourceToggleWrapper></>)
   }), diffSourcePlugin()]}
 />