Quill富文本编辑器
Quill 是一个开源的富文本编辑器,旨在实现兼容性和可扩展性。
特性:
-
快速且轻量级
-
语意标签
-
标准化 HTML
-
支持 Chrome, Firefox, Safari, and IE 9+
使用方法:
<!-- Include Quill stylesheet --> <link href="https://cdn.quilljs.com/1.0.0/quill.snow.css" rel="stylesheet"> <!-- Create the toolbar container --> <div id="toolbar"> <button class="ql-bold">Bold</button> <button class="ql-italic">Italic</button> </div> <!-- Create the editor container --> <div id="editor"> <p>Hello World!</p> </div> <!-- Include the Quill library --> <script src="https://cdn.quilljs.com/1.0.0/quill.js"></script> <!-- Initialize Quill editor --> <script> var editor = new Quill('#editor', { modules: { toolbar: '#toolbar' }, theme: 'snow' }); </script>
评论