sparksuite / simplemde-markdown-editor

A simple, beautiful, and embeddable JavaScript Markdown editor. Delightful editing for beginners and experts alike. Features built-in autosaving and spell checking.
https://simplemde.com
MIT License
9.79k stars 1.12k forks source link

Selective markdown support #756

Open hwsamuel opened 5 years ago

hwsamuel commented 5 years ago

Is it possible to choose what markdown is allowed? For example, I would like to disable all headers related markdown such as #, ##, etc.

To clarify further, I already know how to hide markdown options in the toolbar (sample code below). But this doesn't prevent someone knowledgeable in markdown to still insert any supported markdown into the editor and get a preview.

    var simplemde = new SimpleMDE({
        element: document.getElementById("blogtext"),
        toolbar: ["bold","italic","strikethrough","quote","|","ordered-list","unordered-list","|","link","image","|","preview","|","guide"],
        forceSync: true,
        status: false,
        spellChecker: false
    });
the-darc commented 3 years ago

+1