@tryheliumai/paywall-sdk-react-native 0.1.12 → 0.1.13
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/README.md +24 -0
- package/package.json +13 -3
package/README.md
CHANGED
|
@@ -26,6 +26,30 @@ cd ..
|
|
|
26
26
|
npx react-native link @tryheliumai/paywall-sdk-react-native
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
+
### TypeScript Configuration
|
|
30
|
+
|
|
31
|
+
If you encounter TypeScript errors related to module resolution, you may need to update your `tsconfig.json` file. The SDK uses modern module resolution, so you'll need to set the `moduleResolution` option to one of the following:
|
|
32
|
+
|
|
33
|
+
```json
|
|
34
|
+
{
|
|
35
|
+
"compilerOptions": {
|
|
36
|
+
"moduleResolution": "node16" // or "nodenext" or "bundler"
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Alternatively, you can add a `paths` entry to your `tsconfig.json`:
|
|
42
|
+
|
|
43
|
+
```json
|
|
44
|
+
{
|
|
45
|
+
"compilerOptions": {
|
|
46
|
+
"paths": {
|
|
47
|
+
"@tryheliumai/paywall-sdk-react-native": ["./node_modules/@tryheliumai/paywall-sdk-react-native/lib/typescript/module/src/index.d.ts"]
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
29
53
|
## **Configuration**
|
|
30
54
|
|
|
31
55
|
### Provider Setup
|
package/package.json
CHANGED
|
@@ -1,10 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tryheliumai/paywall-sdk-react-native",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.13",
|
|
4
4
|
"description": "Paywall SDK Helium",
|
|
5
5
|
"source": "./src/index.ts",
|
|
6
6
|
"main": "./lib/commonjs/index.js",
|
|
7
7
|
"module": "./lib/module/index.js",
|
|
8
|
+
"types": "./lib/typescript/module/src/index.d.ts",
|
|
9
|
+
"typesVersions": {
|
|
10
|
+
"*": {
|
|
11
|
+
"*": [
|
|
12
|
+
"./lib/typescript/module/src/index.d.ts"
|
|
13
|
+
]
|
|
14
|
+
}
|
|
15
|
+
},
|
|
8
16
|
"exports": {
|
|
9
17
|
".": {
|
|
10
18
|
"import": {
|
|
@@ -14,7 +22,8 @@
|
|
|
14
22
|
"require": {
|
|
15
23
|
"types": "./lib/typescript/commonjs/src/index.d.ts",
|
|
16
24
|
"default": "./lib/commonjs/index.js"
|
|
17
|
-
}
|
|
25
|
+
},
|
|
26
|
+
"types": "./lib/typescript/module/src/index.d.ts"
|
|
18
27
|
}
|
|
19
28
|
},
|
|
20
29
|
"files": [
|
|
@@ -175,7 +184,8 @@
|
|
|
175
184
|
"typescript",
|
|
176
185
|
{
|
|
177
186
|
"project": "tsconfig.build.json",
|
|
178
|
-
"esm": true
|
|
187
|
+
"esm": true,
|
|
188
|
+
"tscOptions": ["--declaration", "--emitDeclarationOnly"]
|
|
179
189
|
}
|
|
180
190
|
]
|
|
181
191
|
]
|