mirror of
https://github.com/sparksuite/simplemde-markdown-editor.git
synced 2024-06-26 01:10:15 +02:00
Added more tests for the types file.
This commit is contained in:
parent
5a37a534dc
commit
5b01fba882
|
@ -1,4 +1,5 @@
|
|||
new EasyMDE({
|
||||
// Create new instance
|
||||
const editor = new EasyMDE({
|
||||
autoDownloadFontAwesome: false,
|
||||
element: document.getElementById("mdEditor")!,
|
||||
hideIcons: ["side-by-side", "fullscreen"],
|
||||
|
@ -6,5 +7,20 @@ new EasyMDE({
|
|||
drawTable: "Cmd-Alt-T",
|
||||
toggleFullScreen: null
|
||||
},
|
||||
spellChecker: false
|
||||
spellChecker: false,
|
||||
onToggleFullScreen: (full: boolean) => { console.log('FullscreenToggled', full); },
|
||||
theme: 'someOtherTheme',
|
||||
});
|
||||
|
||||
// Editor functions
|
||||
const value = editor.value() as string;
|
||||
editor.value(value.toUpperCase());
|
||||
|
||||
const sbs = editor.isSideBySideActive() as boolean;
|
||||
const fullscreen = editor.isFullscreenActive() as boolean;
|
||||
|
||||
// Access to codemirror object
|
||||
editor.codemirror.setOption('readOnly', true);
|
||||
|
||||
// Static properties
|
||||
EasyMDE.toggleItalic = (editor: EasyMDE) => { console.log('SomeButtonOverride'); };
|
||||
|
|
Loading…
Reference in a new issue