@fasttrack-solutions/rewards 0.0.0 → 1.44.0-beta.0

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.
package/index.d.ts ADDED
@@ -0,0 +1,6 @@
1
+ // The package is imported for its side effect: it starts the Rewards SDK, which
2
+ // reads the window.* configuration your site already sets. It exports nothing.
3
+ //
4
+ // It deliberately declares no window.* types, so it can never conflict with the
5
+ // declarations your own code already has for window.fasttrack and friends.
6
+ export {};
package/package.json CHANGED
@@ -1,9 +1,45 @@
1
1
  {
2
2
  "name": "@fasttrack-solutions/rewards",
3
- "version": "0.0.0",
4
- "description": "Placeholder: the first release is published by CI.",
3
+ "version": "1.44.0-beta.0",
4
+ "description": "Fast Track Rewards SDK and web components, as an npm package. Same build as the CDN script, with nothing loaded from the CDN.",
5
+ "homepage": "https://www.fasttrack.ai/en/resources/integration/rewards/front-end-integration",
5
6
  "license": "UNLICENSED",
6
- "repository": { "type": "git", "url": "git+https://github.com/fasttrack-solutions/rewards-components.git" },
7
- "files": ["README.md"],
8
- "publishConfig": { "access": "public" }
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "git+https://github.com/fasttrack-solutions/rewards-components.git"
10
+ },
11
+ "files": [
12
+ "dist",
13
+ "ssr.js",
14
+ "index.d.ts",
15
+ "README.md"
16
+ ],
17
+ "type": "module",
18
+ "sideEffects": true,
19
+ "main": "./dist/rewards.js",
20
+ "module": "./dist/rewards.js",
21
+ "types": "./index.d.ts",
22
+ "exports": {
23
+ ".": {
24
+ "types": "./index.d.ts",
25
+ "node": "./ssr.js",
26
+ "deno": "./ssr.js",
27
+ "workerd": "./ssr.js",
28
+ "edge-light": "./ssr.js",
29
+ "react-server": "./ssr.js",
30
+ "default": "./dist/rewards.js"
31
+ },
32
+ "./package.json": "./package.json"
33
+ },
34
+ "publishConfig": {
35
+ "access": "public"
36
+ },
37
+ "peerDependencies": {
38
+ "@fasttrack-solutions/rewards-games": "1.44.0-beta.0"
39
+ },
40
+ "peerDependenciesMeta": {
41
+ "@fasttrack-solutions/rewards-games": {
42
+ "optional": true
43
+ }
44
+ }
9
45
  }
package/ssr.js ADDED
@@ -0,0 +1,4 @@
1
+ // Server-side imports (Next.js, Nuxt, Vite SSR) resolve here through the "node"
2
+ // export condition. The SDK needs a browser page, so on a server importing the
3
+ // package does nothing; the browser bundle starts the SDK as usual.
4
+ export {};