kwinyyyc / strapi-plugin-wysiwyg-react-md-editor

This is a strapi rich text editor plugin based on react md editor
https://www.npmjs.com/package/strapi-plugin-wysiwyg-react-md-editor
MIT License
40 stars 14 forks source link

Custom blocks #27

Open christianpredebon opened 9 months ago

christianpredebon commented 9 months ago

Hi! Is there a way to define custom blocks which are easily reusable through the editor? Something like a NoticeAlert component that will have a yellow background, a ErrorAlert component that will have a red background and so on.

I'm using react-markdown-preview to client side rendering the result.

Thanks

kwinyyyc commented 9 months ago

@christianpredebon Hi, I am not aware of any way the editor can achieve this by default. Let me know if you know any editor that has this feature I can have a reference to.

For the custom block, do you mean the react-markdown-preview would automatically render a certain type of markdown into a React component?

What would be the markdown for NoticeAlert?

Would help if you could share more on your use case, cause it doesn't sound like a common use case.