Comparing version 1.0.3 to 1.0.4
@@ -78,4 +78,2 @@ "use strict"; | ||
var locationF = location.replace('https://', ''); | ||
console.log(merchantNameF, locationF, amountF); | ||
console.log(merchantNameF.length, locationF.length, amountF.length); | ||
// Check for input problems | ||
@@ -82,0 +80,0 @@ if (merchantNameF.length < 1 || locationF.length < 1 || amountF.length < 1) { |
{ | ||
"name": "pix-charge", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "Library to generate BCB's Pix Payment BR Code", | ||
@@ -5,0 +5,0 @@ "main": "dist/src/index.js", |
@@ -8,3 +8,3 @@ # pix-charge | ||
![pixLogo](https://cdn-std.droplr.net/files/acc_519625/Ql2F31) | ||
![pixLogo](https://cdn-std.droplr.net/files/acc_519625/NU7Nzk) | ||
@@ -26,4 +26,5 @@ Library to generate BCB's Pix Payment BR Code 💸 | ||
```js | ||
import { dinamicPix, staticPix } from "pix-charge"; | ||
import { staticPix } from "pix-charge"; | ||
// Payer will set transfer value | ||
let brCode = staticPix({ | ||
@@ -33,2 +34,17 @@ merchantKey: "gjmolter.1997@gmail.com", | ||
}); | ||
// Transfer value is pre-defined. | ||
let brCodeWithValue = staticPix({ | ||
merchantKey: "gjmolter.1997@gmail.com", | ||
merchantName: "Gabriel Molter", | ||
amount: 1.99, | ||
}); | ||
// Transfer value is pre-defined and has charge description | ||
let brCodeWithValue = staticPix({ | ||
merchantKey: "gjmolter.1997@gmail.com", | ||
merchantName: "Gabriel Molter", | ||
amount: 1.99, | ||
description: "Candy Bar", // Will show up as a label describing to the payer what they are being charged for | ||
}); | ||
``` | ||
@@ -86,5 +102,5 @@ | ||
`staticPix({ object })`. object: | ||
`staticPix({ object })`: | ||
| param | type | required | | ||
| object key | type | required | | ||
| ------------ | ------- | -------- | | ||
@@ -101,9 +117,9 @@ | merchantKey | string | ✅ | | ||
`dinamicPix({ object })`. object: | ||
`dinamicPix({ object })`: | ||
| param | type | required | | ||
| object key | type | required | | ||
| ------------ | ------- | -------- | | ||
| merchantName | string | ✅ | | ||
| location | string | ✅ | | ||
| amount | number | ❌ | | ||
| amount | number | ✅ | | ||
| merchantCity | string | ❌ | | ||
@@ -110,0 +126,0 @@ | merchantCep | string | ❌ | |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15273
155
413