@rebilly/risk-data-collector 4.15.4 → 4.15.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/README.md +16 -14
  3. package/package.json +5 -3
package/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ ## [4.15.6](https://github.com/Rebilly/rebilly/compare/risk-data-collector-v4.15.5...risk-data-collector-v4.15.6) (2024-03-11)
2
+
3
+ ## [4.15.5](https://github.com/Rebilly/rebilly/compare/risk-data-collector-v4.15.4...risk-data-collector-v4.15.5) (2024-03-06)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **risk-data-collector:** Prettier improvements ([#3861](https://github.com/Rebilly/rebilly/issues/3861)) ([feec7fe](https://github.com/Rebilly/rebilly/commit/feec7fe1334289d31537064c2bb71e93064d9250))
9
+
1
10
  ## [4.15.4](https://github.com/Rebilly/rebilly/compare/risk-data-collector-v4.15.3...risk-data-collector-v4.15.4) (2024-03-05)
2
11
 
3
12
 
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  [![npm version](https://badge.fury.io/js/@rebilly%2Frisk-data-collector.svg)](https://badge.fury.io/js/@rebilly%2Frisk-data-collector)
4
4
 
5
- Collect browser data for risk assessment purposes.
5
+ Collect browser data for risk assessment purposes.
6
6
 
7
7
  ## Description
8
8
 
@@ -38,10 +38,11 @@ The library becomes available under the `RiskDataCollector` global namespace and
38
38
  (async () => {
39
39
  const browserData = await RiskDataCollector.collectData();
40
40
  console.log(`browserData is: ${JSON.stringify(browserData)}`);
41
- })()
41
+ })();
42
42
  </script>
43
43
  </body>
44
- <html>
44
+ <html></html>
45
+ </html>
45
46
  ```
46
47
 
47
48
  > Note: You can replace `@latest` with `@<version>` (Example `@1.0.0`). To pin to a specific version.
@@ -57,32 +58,33 @@ npm install @rebilly/risk-data-collector
57
58
  Which can be imported and used like so:
58
59
 
59
60
  ```js
60
- import {collectData} from '@rebilly/risk-data-collector';
61
+ import { collectData } from '@rebilly/risk-data-collector';
61
62
 
62
63
  (async () => {
63
64
  const browserData = await collectData();
64
65
  console.log(`browserData is: ${JSON.stringify(browserData)}`);
65
- })()
66
+ })();
66
67
  ```
67
68
 
68
- ## Kount
69
+ ## Kount
69
70
 
70
71
  `risk-data-collector` works with [Kount](https://kount.com/) to collect `kountFraudSessionId`.
71
72
 
72
- If you already have an account with Kount, you can use it with `risk-data-collector` by providing:
73
+ If you already have an account with Kount, you can use it with `risk-data-collector` by providing:
74
+
75
+ - `env` - `sandbox` or `production`, determines which Kount environment to use (defaults to `sandbox`)
76
+ - `kountAccountId` - your Kount account ID
77
+ - (optional) `kountSessionId` - 32 character session ID, omit to have Kount generate a session ID for you
73
78
 
74
- - `env` - `sandbox` or `production`, determines which Kount environment to use (defaults to `sandbox`)
75
- - `kountAccountId` - your Kount account ID
76
- - (optional) `kountSessionId` - 32 character session ID, omit to have Kount generate a session ID for you
77
-
78
79
  Example:
79
80
 
80
81
  ```js
81
- import {collectData} from '@rebilly/risk-data-collector';
82
+ import { collectData } from '@rebilly/risk-data-collector';
82
83
 
83
84
  (async () => {
84
85
  const env = 'production';
85
86
  const kountAccountId = '123456';
86
87
  const browserData = await collectData({ env, kountAccountId });
87
- console.log(`browserData is: ${JSON.stringify(browserData)}`)
88
- })()
88
+ console.log(`browserData is: ${JSON.stringify(browserData)}`);
89
+ })();
90
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rebilly/risk-data-collector",
3
- "version": "4.15.4",
3
+ "version": "4.15.6",
4
4
  "description": "Microlibrary that collects browser data for risk assessment",
5
5
  "type": "module",
6
6
  "main": "dist/data-collector.js",
@@ -8,8 +8,10 @@
8
8
  "author": "Rebilly",
9
9
  "license": "MIT",
10
10
  "scripts": {
11
- "lint": "eslint src cypress --fix --max-warnings 0",
12
- "lint:no-fix": "yarn lint --no-fix",
11
+ "format": "prettier --write .",
12
+ "format:check": "prettier --check .",
13
+ "lint": "yarn format && eslint src cypress --fix --max-warnings 0",
14
+ "lint:no-fix": "yarn format:check && yarn lint --no-fix",
13
15
  "build": "rollup -c",
14
16
  "build:watch": "rollup -c --watch",
15
17
  "cypress:open": "cypress open",