feat: Add setAlipaySandbox props.
This commit is contained in:
parent
e91767ef52
commit
afa8dee9b6
@ -25,6 +25,8 @@ import Alipay from 'react-native-uiwjs-alipay';
|
||||
// 设置 支付宝 URL Schemes
|
||||
// scheme = `ap` + `APPID`
|
||||
Alipay.setAlipayScheme(scheme);
|
||||
// 设置支付宝沙箱环境
|
||||
Alipay.setAlipaySandbox(isSandbox);
|
||||
// 支付宝 iOS 端的支付
|
||||
// payInfo 是后台拼接好的支付参数
|
||||
Alipay.alipay(payInfo, (res)=>console.log(res))
|
||||
|
5
index.d.ts
vendored
5
index.d.ts
vendored
@ -54,6 +54,11 @@ export const Alipay: {
|
||||
* @param scheme scheme = `ap` + `APPID`
|
||||
*/
|
||||
setAlipayScheme: (scheme: string) => void;
|
||||
/**
|
||||
* 设置支付宝沙箱环境,仅 Android
|
||||
* @param isSandBox
|
||||
*/
|
||||
setAlipaySandbox: (isSandbox: boolean) => void;
|
||||
};
|
||||
|
||||
export default Alipay;
|
Loading…
Reference in New Issue
Block a user