nhn / tui.editor

🍞📝 Markdown WYSIWYG Editor. GFM Standard + Chart & UML Extensible.
http://ui.toast.com/tui-editor
MIT License
16.91k stars 1.72k forks source link

Do not escape underscores in markdown #3185

Open ahamelers opened 9 months ago

ahamelers commented 9 months ago

Version

3.2.3

Development Environment

React editor, editor, Node

Current Behavior

WYSIWYG :

test_test_test

Markdown :

test\_test\_test

Expected Behavior

I would like to reopen https://github.com/nhn/tui.editor/issues/715 for the new version of the editor.

The underscores in snake_case_filenames, etc., should not be escaped. Right now, it can't even be changed with plugins, and if the resulting markdown contains a lot of file names (for example) the plain text is difficult to read and impossible to copy/paste from.

The escaping functionality should be configurable to exclude these. If that has to also go hand in hand with only allowing * instead of _ for italic emphasis, that's fine! But it should be an option.