Search code examples
wysiwygsummernote

summernote: how to add a "italic" button show it stay next to the bold and underline buttons?


I am new to summernote. I hope to add a "italic" button next to the bold and underline buttons because it is such a common edit operation. I am unable to find examples of how to do it.

Thanks for any help!


Solution

  • I think that's by default. But you can of course customize your own toolbar.

    $('.summernote').summernote({
      toolbar: [
        //[groupname, [button list]]
        ['style', ['bold', 'italic', 'underline', 'clear']]
    ]
    });
    

    You can read more about custom toolbar here.