fix emmet undefined in non-html challenges
This commit is contained in:
@ -216,13 +216,15 @@ var allSeeds = '';
|
|||||||
});
|
});
|
||||||
})();
|
})();
|
||||||
|
|
||||||
var defaultKeymap = {
|
if (typeof emmetCodeMirror !== 'undefined') {
|
||||||
'Cmd-E': 'emmet.expand_abbreviation',
|
var defaultKeymap = {
|
||||||
'Tab': 'emmet.expand_abbreviation_with_tab',
|
'Cmd-E': 'emmet.expand_abbreviation',
|
||||||
'Enter': 'emmet.insert_formatted_line_break_only'
|
'Tab': 'emmet.expand_abbreviation_with_tab',
|
||||||
};
|
'Enter': 'emmet.insert_formatted_line_break_only'
|
||||||
|
};
|
||||||
|
|
||||||
emmetCodeMirror(editor, defaultKeymap);
|
emmetCodeMirror(editor, defaultKeymap);
|
||||||
|
}
|
||||||
|
|
||||||
editor.setOption('extraKeys', {
|
editor.setOption('extraKeys', {
|
||||||
Tab: function(cm) {
|
Tab: function(cm) {
|
||||||
|
Reference in New Issue
Block a user