eventlog-rn 0.3.1 → 0.3.3

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 (2) hide show
  1. package/README.md +25 -16
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -8,19 +8,29 @@
8
8
 
9
9
  ## What is this?
10
10
 
11
- # eventlog-rn
11
+ **eventlog-rn** is a local-first activity tracker for React Native that helps you understand user behavior and debug issues by recording screens, actions, and errors.
12
+
13
+ It is designed to be **safe**, **fast**, and **privacy-focused**:
14
+ - 🏃‍♂️ **Zero performance impact**: Synchronous logging (<1ms) with batched writes.
15
+ - 💾 **Unlimited storage**: Uses MMKV to store thousands of events.
16
+ - 🌐 **Network Logs**: Auto-captures `fetch` and `XMLHttpRequest`.
17
+ - 🚨 **Error Handling**: Captures crashes, promise rejections, and React render errors.
18
+ - 🛡️ **Privacy-first**: Data stays on the device. you control when to export.
19
+ - 🧩 **Type-safe**: Built with strict TypeScript and result types for robust error handling.
20
+
21
+ This is **not** a cloud analytics platform. It is a tool for developers to capture local context and user journeys for debugging and support.
12
22
 
13
- Functional, type-safe event logging SDK for React Native.
23
+ <p align="center">
24
+ <img src="https://github.com/nainglynndw/eventlog-rn/raw/main/packages/core/assets/list.png" width="200" alt="Event List" />
25
+ <img src="https://github.com/nainglynndw/eventlog-rn/raw/main/packages/core/assets/filtering.png" width="200" alt="Filtering" />
26
+ <img src="https://github.com/nainglynndw/eventlog-rn/raw/main/packages/core/assets/details.png" width="200" alt="Event Details" />
27
+ <img src="https://github.com/nainglynndw/eventlog-rn/raw/main/packages/core/assets/network.png" width="200" alt="Network Details" />
28
+ </p>
14
29
 
15
- Optimized for **reliability**, **performance**, and **ease of use**.
16
30
 
17
- ## Features
31
+ ## Documentation
18
32
 
19
- - **Type-Safe**: Full TypeScript support with generics.
20
- - **Batched Uploads**: Efficiently queues events to minimize network requests.
21
- - **Offline Support**: Caches events when offline and syncs when back online.
22
- - **Session Tracking**: Automatic session management.
23
- - **Built-in UI**: Inspect logs on-device with the included Viewer component.
33
+ 📚 **[Read the Full Documentation](https://nainglynndw.github.io/eventlog-rn/)**
24
34
 
25
35
  ## Quick Start
26
36
 
@@ -35,12 +45,8 @@ npm install eventlog-rn react-native-mmkv
35
45
  ```typescript
36
46
  import { eventLog } from 'eventlog-rn';
37
47
 
38
- // Initialize at app launch based on your config
39
- eventLog.init({
40
- // ...
41
- });
42
- ```
43
- Network logging enabled by default!
48
+ // 1. Initialize (call once at app start)
49
+ await eventLog.init(); // Network logging enabled by default!
44
50
 
45
51
  // 2. Log events
46
52
  eventLog.screen('HomeScreen');
@@ -48,8 +54,11 @@ eventLog.action('button_clicked', { buttonId: 'checkout' });
48
54
 
49
55
  // 3. Export for debugging
50
56
  const result = await eventLog.export({ mode: 'repro' });
57
+ ```
58
+
59
+ ### 3. View logs (optional)
51
60
 
52
- // 4. View logs (optional)
61
+ ```tsx
53
62
  import { EventLogViewer, EventLogErrorBoundary } from 'eventlog-rn';
54
63
 
55
64
  // Wrap app for error handling
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eventlog-rn",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "description": "Functional, type-safe event logging SDK for React Native",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",