Page tree
Skip to end of metadata
Go to start of metadata

Programmatically sets the editor's mode to either code or design mode.

Example

// put the editor instance explicitly into code mode
editor.mode.set('code');
 
 
//put the editor instance explicitly into design mode
editor.mode.set('design');

Parameters

modeStringEither code or design for code or design views respectively. If any other values are used, an error is thrown.

Returns

No return value.

  • No labels