A package to handle payments using Stripe or Lemonsqueezy using a single interface.
Why do we need this?
I run supersaas.dev, a fullstack saas template that allows you to create your own saas. I wanted to make it easy for people to add payments to their saas without having to deal with the nuances of each payment provider.
You get a single interface to handle payments, subscriptions, managing billing etc.
usePayment("stripe").createCheckoutLink(options);
usePayment("lemonsqueezy").createCheckoutLink(options);
- Stripe
- Lemonsqueezy
- Paddle (WIP)
- Paypal (WIP)
- Creem (WIP)
- Polar.sh (WIP)
Install package:
# ✨ Auto-detect
npx nypm install use-payment
# npm
npm install use-payment
# yarn
yarn add use-payment
# pnpm
pnpm install use-payment
# bun
bun install use-payment
# deno
deno install use-payment
Import:
ESM (Node.js, Bun, Deno)
import {} from "use-payment";
CommonJS (Legacy Node.js)
const {} = require("use-payment");
CDN (Deno, Bun and Browsers)
import {} from "https://esm.sh/use-payment";
local development
Published under the MIT license.
Made by community 💛
🤖 auto updated with automd