mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
feat(monorepo): build with esm modules (#8729)
fixes https://github.com/NativeScript/NativeScript/issues/8739
This commit is contained in:
committed by
Nathan Walker
parent
5658e638d5
commit
fc64fc3ed9
@@ -31,13 +31,6 @@ function ensureImageSource() {
|
||||
}
|
||||
}
|
||||
|
||||
let platform: typeof platformModule;
|
||||
function ensurePlatform() {
|
||||
if (!platform) {
|
||||
platform = require('../../platform');
|
||||
}
|
||||
}
|
||||
|
||||
let fs: typeof fsModule;
|
||||
function ensureFileSystem() {
|
||||
if (!fs) {
|
||||
@@ -205,8 +198,6 @@ function buildJavaOptions(options: httpModule.HttpRequestOptions) {
|
||||
javaOptions.headers = arrayList;
|
||||
}
|
||||
|
||||
ensurePlatform();
|
||||
|
||||
// pass the maximum available image size to the request options in case we need a bitmap conversion
|
||||
javaOptions.screenWidth = Screen.mainScreen.widthPixels;
|
||||
javaOptions.screenHeight = Screen.mainScreen.heightPixels;
|
||||
|
||||
@@ -31,6 +31,7 @@ function parseJSON(source: string): any {
|
||||
return JSON.parse(src);
|
||||
}
|
||||
|
||||
@NativeClass
|
||||
class NSURLSessionTaskDelegateImpl extends NSObject implements NSURLSessionTaskDelegate {
|
||||
public static ObjCProtocols = [NSURLSessionTaskDelegate];
|
||||
public URLSessionTaskWillPerformHTTPRedirectionNewRequestCompletionHandler(session: NSURLSession, task: NSURLSessionTask, response: NSHTTPURLResponse, request: NSURLRequest, completionHandler: (p1: NSURLRequest) => void): void {
|
||||
|
||||
Reference in New Issue
Block a user