@blinkbitcoin/blink-client
v0.5.2
Published
JavaScript client library for the Blink stack. This is used in front-end applications like the web and mobile wallets.
Readme
Galoy Client
JavaScript client library for the Blink stack. This is used in front-end applications like the web and mobile wallets.
Installation
Install the package with:
yarn add @blinkbitcoin/blink-clientUsage
parsePaymentDestination
import { parsePaymentDestination } from "@blinkbitcoin/blink-client"
const { valid, paymentType, amount } = parsePaymentDestination({
destination: "username or invoice or bitcoin address",
network: "mainnet", // or signet or regtest
})Test
Test with Jest framework:
pnpm testBuild
Build production (distribution) files in dist folder:
pnpm buildLocal development
Run:
pnpm link --globaland in your test project run:
pnpm link --global @blinkbitcoin/blink-clientIf you want to remove the link, run:
# in your test project
pnpm unlink @blinkbitcoin/blink-client
# in blinkbitcoin/client folder
pnpm unlink --globalRun:
yarn linkand in your test project run:
yarn link @galoymoney/clientIf you want to remove the symlink, run:
# in your test project
yarn unlink @galoymoney/client
# in galoymoney/client folder
yarn unlinkRun:
# in galoymoney/client folder
yalc publishin your test project run:
yalc add @galoymoney/clientIf you want to remove the symlink, run:
# in your test project
yalc remove @galoymoney/clientto update changes, you have to run yalc publish before run:
# in your test project
yalc update