@lcap/nasl-utils
Advanced tools
Comparing version 3.10.0-rc.1 to 3.10.2-alpha.connector.1
@@ -13,2 +13,4 @@ /** 浏览器环境 */ | ||
export declare const isAutoTestEnv: boolean; | ||
/** 是否可用全局接口 */ | ||
export declare const isSupportRequestIdleCallback: boolean; | ||
//# sourceMappingURL=env.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.isAutoTestEnv = exports.isTestBrowser = exports.isDebugMode = exports.isLocalMode = exports.isNode = exports.isBrowser = void 0; | ||
exports.isSupportRequestIdleCallback = exports.isAutoTestEnv = exports.isTestBrowser = exports.isDebugMode = exports.isLocalMode = exports.isNode = exports.isBrowser = void 0; | ||
/** 浏览器环境 */ | ||
@@ -16,2 +16,4 @@ exports.isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined'; | ||
exports.isAutoTestEnv = exports.isBrowser && Boolean(window.RUN_AUTO_TEST); | ||
/** 是否可用全局接口 */ | ||
exports.isSupportRequestIdleCallback = exports.isBrowser && 'requestIdleCallback' in window; | ||
//# sourceMappingURL=env.js.map |
@@ -8,2 +8,3 @@ "use strict"; | ||
const constant_1 = require("./constant"); | ||
const env_1 = require("../env"); | ||
/** 时间分片控制器 */ | ||
@@ -227,3 +228,3 @@ class TimeSlicingController { | ||
this.setFrameEnd(); | ||
if (utils_1.isSupportRequestIdleCallback) { | ||
if (env_1.isSupportRequestIdleCallback) { | ||
requestIdleCallback(runFrame, { | ||
@@ -230,0 +231,0 @@ timeout: 10, |
@@ -40,4 +40,2 @@ export interface TaskDataInDebug { | ||
export declare function getId(): number; | ||
/** 是否可用全局接口 */ | ||
export declare const isSupportRequestIdleCallback: boolean; | ||
/** 延迟 */ | ||
@@ -44,0 +42,0 @@ export declare function delay(time?: number): Promise<void>; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.returnOrigin = exports.isGenerator = exports.getFrameMark = exports.getGroupMark = exports.getAsyncMark = exports.delay = exports.isSupportRequestIdleCallback = exports.getId = void 0; | ||
const env_1 = require("../env"); | ||
exports.returnOrigin = exports.isGenerator = exports.getFrameMark = exports.getGroupMark = exports.getAsyncMark = exports.delay = exports.getId = void 0; | ||
/** 编号 */ | ||
@@ -11,4 +10,2 @@ let id = 0; | ||
exports.getId = getId; | ||
/** 是否可用全局接口 */ | ||
exports.isSupportRequestIdleCallback = env_1.isBrowser && 'requestIdleCallback' in window; | ||
/** 延迟 */ | ||
@@ -15,0 +12,0 @@ function delay(time = 10) { |
{ | ||
"name": "@lcap/nasl-utils", | ||
"description": "NetEase Application Specific Language", | ||
"version": "3.10.0-rc.1", | ||
"version": "3.10.2-alpha.connector.1", | ||
"author": "Forrest <rainforest92@126.com>", | ||
@@ -26,3 +26,3 @@ "main": "./out", | ||
"uuid": "8.3.2", | ||
"@lcap/nasl-types": "3.10.0-rc.1" | ||
"@lcap/nasl-types": "3.10.2-alpha.connector.1" | ||
}, | ||
@@ -29,0 +29,0 @@ "scripts": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
127969
+ Added@lcap/nasl-types@3.10.2-alpha.connector.1(transitive)
- Removed@lcap/nasl-types@3.10.0-rc.1(transitive)