update demo to requirejs 2
This commit is contained in:
parent
f1639ca1d2
commit
01c4cb8ea8
2 changed files with 1343 additions and 1417 deletions
File diff suppressed because it is too large
Load diff
|
|
@ -827,7 +827,8 @@ var EditSession = function(text, mode) {
|
||||||
try {
|
try {
|
||||||
module = require(mode);
|
module = require(mode);
|
||||||
} catch (e) {};
|
} catch (e) {};
|
||||||
if (module)
|
// sometimes require returns empty object (this bug is present in requirejs 2 as well)
|
||||||
|
if (module && module.Mode)
|
||||||
return done(module);
|
return done(module);
|
||||||
|
|
||||||
// set mode to text until loading is finished
|
// set mode to text until loading is finished
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue