考虑到比特币作为支付方式,有没有一种简单的方法,使用react-strip-element来显示启用比特币支付的表单?
有人已经尝试了吗?
我已经使用react-strip-element进行 VISA/万事达卡付款:
import { StripeProvider, Elements } from 'react-stripe-elements';
...
<StripeProvider apiKey={stripePublishableKey}>
<Elements locale={locale}>
<StripeForm paymentConfig={paymentConfig} dispatch={dispatch} buyerName="toget" />
</Elements>
</StripeProvider >
...
我的元素<SripeForm>
仅在一个 和一个提交按钮内<form>
返回<CardElement hidePostalCode style={cardStyle} />
。
我不知道这是否CardElement
可以用于比特币支付,或者我是否必须使用另一个 React Stripe Element。
欢迎任何有关 Stripe 比特币支付的帮助或经验。
编辑
react-strip-element团队给出了这个问题的答案:
我们目前没有任何比特币元素。您可以使用 Stripe Checkout,也可以构建自己的 UI 并使用 Stripe.js v3 创建比特币来源。
所以现在只有一个解决方案:使用 Stripe Checkout 的自定义 React 实现。如果留给我足够的时间来实现它,我会在这里发布它:)。