Fix: use CodeMirror.defineExtension
This commit is contained in:
parent
0ad0c70f7c
commit
2b17c07cd6
|
@ -107,8 +107,8 @@
|
||||||
uso: 'css'
|
uso: 'css'
|
||||||
};
|
};
|
||||||
|
|
||||||
CodeMirror.prototype.setPreprocessor = function(preprocessor) {
|
CodeMirror.defineExtension('setPreprocessor', function (preprocessor) {
|
||||||
this.setOption('mode', MODE[preprocessor] || 'css');
|
this.setOption('mode', MODE[preprocessor] || 'css');
|
||||||
CodeMirror.autoLoadMode(this, MODE[preprocessor] || 'css');
|
CodeMirror.autoLoadMode(this, MODE[preprocessor] || 'css');
|
||||||
};
|
});
|
||||||
})();
|
})();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user