Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hylid/call

Package Overview
Dependencies
Maintainers
0
Versions
119
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hylid/call - npm Package Compare versions

Comparing version 4.0.8 to 4.0.9

4

lib/index.d.ts

@@ -9,2 +9,6 @@ /// <reference types="miniprogram" />

export declare function call<T extends keyof MPApi>(name: T | ({} & string), options?: PickMPArgs<T> | Common | Callback<PickMpReturns<T>>, config?: Config): any;
export declare function callAsync<T = any>(apiName: string, options?: AsyncCallback<T> & any, config?: {
timeout: number;
isSync?: boolean;
}): Promise<any>;
export declare function createWebviewSrc(url: string): string;

@@ -11,0 +15,0 @@ export { WebViewBridge } from './webviewBridge';

@@ -1,2 +0,2 @@

var _a;
var _a, _b;
import { platform, PLATFORM } from '@hylid/env';

@@ -8,2 +8,3 @@ import { mpCall } from "./mpCall";

var callMap = (_a = {}, _a[PLATFORM.MP] = mpCall, _a[PLATFORM.MPWEB] = mpWebCall, _a[PLATFORM.WEB] = webCall, _a);
var callMapAsync = (_b = {}, _b[PLATFORM.MPWEB] = mpWebCallAsync, _b[PLATFORM.WEB] = webCallAsync, _b);
export function call(name, options, config) {

@@ -16,2 +17,9 @@ if (platform) {

}
export function callAsync(apiName, options, config) {
if (platform) {
return callMapAsync[platform](apiName, options, config);
} else {
return Promise.reject(notFound(options, config));
}
}
export function createWebviewSrc(url) {

@@ -18,0 +26,0 @@ var app = my.getSystemInfoSync().app;

@@ -59,2 +59,5 @@ var __assign = this && this.__assign || function () {

export function mpWebCall(api, options, config) {
config = __assign({
timeout: 20000
}, config);
var random = Math.floor(Math.random() * 1000000);

@@ -61,0 +64,0 @@ var serialId = api + '_' + random;

6

package.json
{
"name": "@hylid/call",
"version": "4.0.8",
"version": "4.0.9",
"main": "lib/index.js",

@@ -9,4 +9,4 @@ "files": [

"dependencies": {
"@hylid/env": "^4.0.8",
"@hylid/types": "^4.0.8"
"@hylid/env": "^4.0.9",
"@hylid/types": "^4.0.9"
},

@@ -13,0 +13,0 @@ "publishConfig": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc