【发布时间】:2017-06-19 08:00:06
【问题描述】:
我需要将条带导入我的应用程序
首先我安装了条带 npm 包
npm install stripe --save
Stripe 文档说在连接 api 之前应该设置密钥。
在Node中它喜欢这个
var stripe = require('stripe')(' your stripe API key ');
我需要把它转换成打字稿
我尝试了以下方式。但它对我不起作用
import * as stripe from 'stripe';
stripe('sk_test_...')
如果有人可以帮助我解决这个问题,那将极大地帮助我毫不拖延地继续我的项目。
谢谢
【问题讨论】:
标签: node.js typescript stripe-payments