@kush_hemant/react-api-monitor 1.0.22 → 1.0.24

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/dist/index.js +0 -26
  2. package/package.json +30 -30
package/dist/index.js CHANGED
@@ -117,31 +117,6 @@ function monitorXHR() {
117
117
  };
118
118
  }
119
119
 
120
- // src/network/resourceMonitor.js
121
- function monitorResources() {
122
- if (!window.PerformanceObserver) return;
123
- const observer = new PerformanceObserver((list) => {
124
- list.getEntries().forEach((entry) => {
125
- if (entry.initiatorType === "fetch" || entry.initiatorType === "xmlhttprequest" || entry.initiatorType === "beacon") {
126
- return;
127
- }
128
- if (LOG_ENDPOINT2 && entry.name.includes(LOG_ENDPOINT2)) {
129
- return;
130
- }
131
- sendLog2({
132
- type: "resource",
133
- transport: "resource",
134
- url: entry.name,
135
- method: "GET",
136
- duration: Math.round(entry.duration),
137
- statusCode: 0,
138
- ...getMetadata2()
139
- });
140
- });
141
- });
142
- observer.observe({ entryTypes: ["resource"] });
143
- }
144
-
145
120
  // src/network/monitorAxios.js
146
121
  function monitorAxios() {
147
122
  if (!window.axios) return;
@@ -172,7 +147,6 @@ function startNetworkMonitoring() {
172
147
  monitorFetch();
173
148
  monitorXHR();
174
149
  monitorAxios();
175
- monitorResources();
176
150
  }
177
151
 
178
152
  // src/index.js
package/package.json CHANGED
@@ -1,30 +1,30 @@
1
- {
2
- "name": "@kush_hemant/react-api-monitor",
3
- "version": "1.0.22",
4
- "description": "Automatic API monitoring SDK for React apps",
5
- "type": "module",
6
- "main": "./dist/index.js",
7
- "module": "./dist/index.js",
8
- "exports": {
9
- ".": "./dist/index.js"
10
- },
11
- "files": [
12
- "dist"
13
- ],
14
- "keywords": [
15
- "react",
16
- "monitoring",
17
- "api",
18
- "logging",
19
- "observability"
20
- ],
21
- "author": "Hemant Kushwah",
22
- "license": "MIT",
23
- "devDependencies": {
24
- "tsup": "^8.5.1",
25
- "typescript": "^5.9.3"
26
- },
27
- "scripts": {
28
- "build": "tsup src/index.js --format esm"
29
- }
30
- }
1
+ {
2
+ "name": "@kush_hemant/react-api-monitor",
3
+ "version": "1.0.24",
4
+ "description": "Automatic API monitoring SDK for React apps",
5
+ "type": "module",
6
+ "main": "./dist/index.js",
7
+ "module": "./dist/index.js",
8
+ "exports": {
9
+ ".": "./dist/index.js"
10
+ },
11
+ "files": [
12
+ "dist"
13
+ ],
14
+ "keywords": [
15
+ "react",
16
+ "monitoring",
17
+ "api",
18
+ "logging",
19
+ "observability"
20
+ ],
21
+ "author": "Hemant Kushwah",
22
+ "license": "MIT",
23
+ "devDependencies": {
24
+ "tsup": "^8.5.1",
25
+ "typescript": "^5.9.3"
26
+ },
27
+ "scripts": {
28
+ "build": "tsup src/index.js --format esm"
29
+ }
30
+ }