Markdown wysiwyg Editor and Preview in same Textarea [closed]

拟墨画扇 提交于 2021-02-07 03:22:07

问题


I search for a editor to write Markdown syntax and preview in the same textarea, like Bootstrap WYSIHTML5 for html.

enter image description here

I don't like a additional preview. The preview in additional element have many scripts, there I can find on the web. But for me is important, that the edit element is also the view element, write and see with markdown. Maybe hallo.js is great, but I think it works not with textarea element. Also it is fine, that I can use a small solution, not to oversize for a small list of buttons and functions. The textarea is also important for me, why the user will save with send post in php, also without Javascript. The goal is a simple notes, write markdown, alternative use the buttons to format and see only the formatted content to easy readable.

Hint: I have read question #1 and question #2, but only CK Editor and Aloha is the solution. Two nice projects, but very big for my small requirements.

Thanks a lot for your time.


回答1:


I have found a solution with the showdown and to-markdown, the the result and his source for example. The hint is, that I add a css statement style="display: none;", that hide the textarea with the source, not more. Line in the source file

--> https://github.com/bueltge/Notes




回答2:


But you still want to use markdown?

So I assume you still want to see the markdown-markup and the style: Editor (demo) is a plain text markdown editor, based on codemirror.



来源:https://stackoverflow.com/questions/16796452/markdown-wysiwyg-editor-and-preview-in-same-textarea

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!