@xrayradar/react 0.1.0 → 0.1.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.
Files changed (2) hide show
  1. package/README.md +30 -0
  2. package/package.json +8 -2
package/README.md ADDED
@@ -0,0 +1,30 @@
1
+ # @xrayradar/react
2
+
3
+ XrayRadar SDK for **React** – ErrorBoundary, XrayRadarProvider, useXrayRadar, and re-exports from **@xrayradar/browser** for [XrayRadar](xrayradar.com) error tracking.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install @xrayradar/react
9
+ ```
10
+
11
+ ## Quick start
12
+
13
+ ```tsx
14
+ import { init, captureException, ErrorBoundary } from "@xrayradar/react";
15
+
16
+ init({
17
+ dsn: "https://xrayradar.com/your_project_id",
18
+ authToken: "your-token",
19
+ });
20
+
21
+ function App() {
22
+ return (
23
+ <ErrorBoundary>
24
+ <YourApp />
25
+ </ErrorBoundary>
26
+ );
27
+ }
28
+ ```
29
+
30
+ Requires **React 17+**. For Next.js, use **@xrayradar/nextjs**. Full docs and Remix setup: [XrayRadar-JS-SDK](https://github.com/KingPegasus/XrayRadar-JS-SDK#readme).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xrayradar/react",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "XrayRadar SDK for React – ErrorBoundary, hooks, provider",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -12,7 +12,9 @@
12
12
  "require": "./dist/index.js"
13
13
  }
14
14
  },
15
- "files": ["dist"],
15
+ "files": [
16
+ "dist"
17
+ ],
16
18
  "scripts": {
17
19
  "build": "tsup src/index.tsx --format cjs,esm --dts --clean",
18
20
  "test": "vitest run --passWithNoTests",
@@ -31,5 +33,9 @@
31
33
  "tsup": "^8.0.0",
32
34
  "typescript": "^5.3.3",
33
35
  "vitest": "^4.0.0"
36
+ },
37
+ "repository": {
38
+ "type": "git",
39
+ "url": "https://github.com/KingPegasus/XrayRadar-JS-SDK.git"
34
40
  }
35
41
  }