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

wwEditor에 입력된 전체 text나 전체 text의 길이를 가져올 방법이 있나요? #3200

Open sh0723b opened 8 months ago

sh0723b commented 8 months ago

Summary

getSelectedText(start, end)를 이용해서 wwEditor에 입력된 전체 텍스트를 가져올 수 있는 방법이 있나요? getSelectedText(0, 99999)처럼 end parameter 매우 큰 값으로 넣을 경우엔 에러가 발생하는데 정확한 end 값이 꼭 필요하다면 moveCusorToEnd로 커서를 마지막으로 옮기고 getSelection을 호출해서 입력된 text의 end 값을 찾는 방법 말고 다른 방법이 있을지 문의 드립니다

아니면 getSelectedText 메소드를 쓰지 않고도 에디터에 입력된 일반 text들을 가져오고, widget은 \$\$widgt0 blabla\$\$ 형식으로 가져올 수 있는 방법이 있다면 알려주세요

마지막으로 replaceWithWidget 메소드의 용도와 사용 방법이 무엇인지도 문의 드립니다

Screenshots

If applicable, add screenshots to help explain your question.

Version

3.1.8

Additional context

Add any other context about the problem here.

Minhat-GitHub commented 5 months ago

hello,The following markdwon editor I recommend https://github.com/Vanessa219/vditor https://github.com/imzbf/md-editor-v3 https://github.com/code-farmer-i/vue-markdown-editor