@byhealth/native-app-jssdk
Advanced tools
Comparing version 2.2.0-beta.3 to 2.2.0
@@ -34,5 +34,4 @@ "use strict"; | ||
function getVersion() { | ||
return new Promise(function (resolve, reject) { | ||
return new Promise(function (resolve) { | ||
nativeBridge_1.default('getAPPVersion', createCallback_1.default(resolve)); | ||
setTimeout(function () { return reject(unsupported('getAPPVersion', false)); }, 500); | ||
}); | ||
@@ -253,16 +252,1 @@ } | ||
} | ||
/** | ||
* 提示不支持接口 | ||
* @param api 接口名称 | ||
* @ignore | ||
*/ | ||
function unsupported(api, isThrow) { | ||
if (isThrow === void 0) { isThrow = true; } | ||
var error = new TypeError("Native webview does not support '" + api + "' API"); | ||
if (isThrow) { | ||
throw error; | ||
} | ||
else { | ||
return error; | ||
} | ||
} |
@@ -20,5 +20,4 @@ /* | ||
export function getVersion() { | ||
return new Promise(function (resolve, reject) { | ||
return new Promise(function (resolve) { | ||
nativeBridge('getAPPVersion', createCallback(resolve)); | ||
setTimeout(function () { return reject(unsupported('getAPPVersion', false)); }, 500); | ||
}); | ||
@@ -214,17 +213,2 @@ } | ||
} | ||
/** | ||
* 提示不支持接口 | ||
* @param api 接口名称 | ||
* @ignore | ||
*/ | ||
function unsupported(api, isThrow) { | ||
if (isThrow === void 0) { isThrow = true; } | ||
var error = new TypeError("Native webview does not support '" + api + "' API"); | ||
if (isThrow) { | ||
throw error; | ||
} | ||
else { | ||
return error; | ||
} | ||
} | ||
export { NativeView }; |
{ | ||
"name": "@byhealth/native-app-jssdk", | ||
"version": "2.2.0-beta.3", | ||
"version": "2.2.0", | ||
"description": "By-Health Native App Jssdk.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
84105
1895