@nexly/react-native 0.10.0 → 0.12.1
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/dist/engagement.d.ts +2 -2
- package/dist/engagement.d.ts.map +1 -1
- package/dist/nexly.d.ts.map +1 -1
- package/dist/nexly.js +10 -2
- package/package.json +2 -2
package/dist/engagement.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { type IngestCredentials } from '@nexly/core';
|
|
1
|
+
import { type IngestCredentials, type NexlyClient } from '@nexly/core';
|
|
2
2
|
type EngagementCreds = {
|
|
3
3
|
collectUrl: string;
|
|
4
|
-
client?:
|
|
4
|
+
client?: NexlyClient;
|
|
5
5
|
} & IngestCredentials;
|
|
6
6
|
type StopFn = () => void;
|
|
7
7
|
/**
|
package/dist/engagement.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"engagement.d.ts","sourceRoot":"","sources":["../src/engagement.ts"],"names":[],"mappings":"AACA,OAAO,EAAuB,KAAK,iBAAiB,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"engagement.d.ts","sourceRoot":"","sources":["../src/engagement.ts"],"names":[],"mappings":"AACA,OAAO,EAAuB,KAAK,iBAAiB,EAAE,KAAK,WAAW,EAAE,MAAM,aAAa,CAAA;AAQ3F,KAAK,eAAe,GAAG;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,WAAW,CAAA;CAAE,GAAG,iBAAiB,CAAA;AAqBvF,KAAK,MAAM,GAAG,MAAM,IAAI,CAAA;AAExB;;;;GAIG;AACH,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,eAAe,GAAG,MAAM,CAyCtE"}
|
package/dist/nexly.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nexly.d.ts","sourceRoot":"","sources":["../src/nexly.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"nexly.d.ts","sourceRoot":"","sources":["../src/nexly.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAe,KAAK,SAAS,EAAE,MAAM,aAAa,CAAA;AAmBpE;;;;;;GAMG;AACH,qBAAa,KAAM,SAAQ,SAAS;IAClC,OAAO,CAAC,aAAa,CAAM;IAE3B;;;OAGG;WACU,IAAI,CAAC,OAAO,EAAE,SAAS,GAAG,OAAO,CAAC,KAAK,CAAC;IASrD,+DAA+D;IAC/D,MAAM,CAAC,WAAW,IAAI,KAAK,GAAG,IAAI;gBAItB,IAAI,EAAE,SAAS;IAI3B,yEAAyE;IACzE,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAK7B,+DAA+D;IAC/D,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO;cAKd,SAAS,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO;cAIpD,mBAAmB,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;cAI9C,qBAAqB,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAI1D,cAAc,IAAI,MAAM;IAIxB,eAAe,IAAI,MAAM,IAAI;CASvC"}
|
package/dist/nexly.js
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
|
-
import { NexlyBase } from '@nexly/core';
|
|
1
|
+
import { NexlyBase, NexlyClient } from '@nexly/core';
|
|
2
2
|
import { Platform } from 'react-native';
|
|
3
3
|
import { collectEventMeta, collectSessionMeta } from './device-meta.js';
|
|
4
4
|
import { startEngagementTracking } from './engagement.js';
|
|
5
5
|
import { prewarmIds } from './session.js';
|
|
6
6
|
import { sendPayloadFetch } from './transport.js';
|
|
7
7
|
function defaultClient() {
|
|
8
|
-
|
|
8
|
+
switch (Platform.OS) {
|
|
9
|
+
case 'android':
|
|
10
|
+
return NexlyClient.RNAndroid;
|
|
11
|
+
case 'web':
|
|
12
|
+
return NexlyClient.RNWeb;
|
|
13
|
+
default:
|
|
14
|
+
// ios, and any other Apple platform (macOS, tvOS) — report as rn-ios.
|
|
15
|
+
return NexlyClient.RNIos;
|
|
16
|
+
}
|
|
9
17
|
}
|
|
10
18
|
/**
|
|
11
19
|
* React Native Nexly client. Implements transport via `fetch({ keepalive: true })`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nexly/react-native",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.1",
|
|
4
4
|
"description": "React Native bindings for Nexly: fetch transport, AsyncStorage IDs, AppState engagement on top of @nexly/core",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"react-native": ">=0.72.0"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@nexly/core": "0.
|
|
46
|
+
"@nexly/core": "0.12.1"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@react-native-async-storage/async-storage": "^2.1.2",
|