|
|
@@ -3,20 +3,22 @@
|
|
|
* For licensing, see LICENSE.md.
|
|
|
*/
|
|
|
|
|
|
-/* global document, console */
|
|
|
+/* global document, console, window */
|
|
|
|
|
|
import ClassicEditor from '/ckeditor5/editor-classic/classic.js';
|
|
|
import EnterFeature from '/ckeditor5/enter/enter.js';
|
|
|
import TypingFeature from '/ckeditor5/typing/typing.js';
|
|
|
import ParagraphFeature from '/ckeditor5/paragraph/paragraph.js';
|
|
|
-import UndoFeature from '/ckeditor5/undo/undo.js';
|
|
|
import HeadingFeature from '/ckeditor5/heading/heading.js';
|
|
|
import ImageFeature from '/ckeditor5/image/image.js';
|
|
|
|
|
|
ClassicEditor.create( document.querySelector( '#editor' ), {
|
|
|
- features: [ EnterFeature, TypingFeature, ParagraphFeature, UndoFeature, HeadingFeature, ImageFeature ],
|
|
|
+ features: [ EnterFeature, TypingFeature, ParagraphFeature, HeadingFeature, ImageFeature ],
|
|
|
toolbar: [ 'headings' ]
|
|
|
} )
|
|
|
+.then( editor => {
|
|
|
+ window.editor = editor;
|
|
|
+} )
|
|
|
.catch( err => {
|
|
|
console.error( err.stack );
|
|
|
} );
|