New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mini-types

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mini-types - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

CHANGELOG.md

4

package.json
{
"name": "mini-types",
"version": "0.0.1",
"version": "0.0.2",
"description": "TypeScript declarations for Alipay's mini program.",

@@ -18,3 +18,3 @@ "scripts": {

],
"license": "ISC",
"license": "MIT",
"devDependencies": {

@@ -21,0 +21,0 @@ "dtslint": "^0.7.2"

# mini-types
TypeScript declarations for Alipay's mini program.
> [English Version](./README.en-US.md)
[![npm package](https://img.shields.io/npm/v/mini-types.svg?style=flat-square)](https://www.npmjs.com/package/mini-types)
[![GitHub stars](https://img.shields.io/github/stars/ant-mini-program/mini-types.svg)](https://github.com/ant-mini-program/mini-types/stargazers)
[![GitHub forks](https://img.shields.io/github/forks/ant-mini-program/mini-types.svg)](https://github.com/ant-mini-program/mini-types/network/members)
[![NPM downloads](https://img.shields.io/npm/dm/mini-types.svg?style=flat-square)](https://www.npmjs.com/package/mini-types)
[![GitHub issues](https://img.shields.io/github/issues/ant-mini-program/mini-types.svg)](https://github.com/ant-mini-program/mini-types/issues)
支付宝小程序 TypeScript 声明文件。
## 安装
```
npm install mini-types --save
```
## 使用
在 `tsconfig.json` 文件中指定 `types` 配置。
```json
{
"compilerOptions": {
"types" : ["mini-types"]
}
}
```
## 贡献
如果你有好的意见或建议,欢迎给我们提 [issue](https://github.com/ant-mini-program/mini-types/issues)。

@@ -5,11 +5,4 @@ /**

declare namespace my {
interface ITradePayOptions {
interface ITradePaySuccessResult {
/**
* 接入小程序支付时传入此参数。此参数为支付宝交易号,注意参数有大小写区分
*/
tradeNO: string;
/**
* 调用成功的回调函数
*
* - 9000:订单支付成功

@@ -23,5 +16,22 @@ * - 8000:正在处理中

*/
success?(resultCode: '9000' | '8000' | '4000' | '6001' | '6002' | '6004' | '99'): void;
resultCode: '9000' | '8000' | '4000' | '6001' | '6002' | '6004' | '99';
callbackUrl?: string;
extendInfo?: Record<string, any>;
memo?: string;
result?: any;
}
interface ITradePayOptions {
/**
* 接入小程序支付时传入此参数。此参数为支付宝交易号,注意参数有大小写区分
*/
tradeNO: string;
/**
* 调用成功的回调函数
*/
success?(res: ITradePaySuccessResult): void;
/**
* 调用失败的回调函数

@@ -28,0 +38,0 @@ */

@@ -268,3 +268,3 @@ /**

*/
destructiveBtnIndex: number;
destructiveBtnIndex?: number;

@@ -271,0 +271,0 @@ /**

@@ -8,4 +8,2 @@ // TypeScript Version: 3.3

type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
declare namespace tinyapp {

@@ -12,0 +10,0 @@ /**

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