Skip to content

Latest commit

 

History

History
35 lines (27 loc) · 679 Bytes

markdown.md

File metadata and controls

35 lines (27 loc) · 679 Bytes

Markdown-It

Get the markdown-it object of mavonEditor

method 1: Global Registration

  import mavonEditor from 'mavon-editor'
  Vue.use(mavonEditor)
  ...
  mavonEditor.markdownIt

method 2: Local Registration

  import {mavonEditor} from 'mavon-editor'
  mavonEditor.mixins[0].data().s_markdown

method 3: Use mavonEditor ref

   <mavonEditor ref=md></mavonEditor>
   ...
   this.refs.md.s_markdown

Use markdown-it object

eg: set the line break style

    // get markdownIt as above
    markdownIt.set({ breaks: false });

markdown-it API