mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
fix-next: Add accidentally removed System.import (#7706)
This commit is contained in:
committed by
Svetoslav
parent
f3bd2e9c5b
commit
efdd7e625c
@@ -23,3 +23,15 @@ global.zonedCallback = function (callback: Function): Function {
|
||||
return callback;
|
||||
}
|
||||
};
|
||||
|
||||
(<any>global).System = {
|
||||
import(path) {
|
||||
return new Promise((resolve, reject) => {
|
||||
try {
|
||||
resolve(global.require(path));
|
||||
} catch (e) {
|
||||
reject(e);
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user