@djangocfg/monitor 2.1.234 → 2.1.235
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/client.cjs +4 -4
- package/dist/client.cjs.map +1 -1
- package/dist/client.d.cts +3 -7
- package/dist/client.d.ts +3 -7
- package/dist/client.mjs +4 -4
- package/dist/client.mjs.map +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/server.cjs.map +1 -1
- package/dist/server.mjs.map +1 -1
- package/package.json +2 -2
- package/src/client/utils/env.ts +4 -8
package/dist/client.d.cts
CHANGED
|
@@ -154,16 +154,12 @@ declare function useDebugMode(): boolean;
|
|
|
154
154
|
|
|
155
155
|
/**
|
|
156
156
|
* Environment utilities.
|
|
157
|
-
*
|
|
158
|
-
* Use these constants instead of inline process.env.NODE_ENV checks.
|
|
159
|
-
* Webpack/esbuild replaces process.env.NODE_ENV statically at build time,
|
|
160
|
-
* so these are zero-cost — they tree-shake correctly in both client and server bundles.
|
|
161
157
|
*/
|
|
162
|
-
/** True only in
|
|
158
|
+
/** True only in next dev / jest / vitest */
|
|
163
159
|
declare const isDevelopment: boolean;
|
|
164
|
-
/** True in
|
|
160
|
+
/** True in any non-development environment */
|
|
165
161
|
declare const isProduction: boolean;
|
|
166
|
-
/** Package version
|
|
162
|
+
/** Package version */
|
|
167
163
|
declare const MONITOR_VERSION: string;
|
|
168
164
|
|
|
169
165
|
/**
|
package/dist/client.d.ts
CHANGED
|
@@ -154,16 +154,12 @@ declare function useDebugMode(): boolean;
|
|
|
154
154
|
|
|
155
155
|
/**
|
|
156
156
|
* Environment utilities.
|
|
157
|
-
*
|
|
158
|
-
* Use these constants instead of inline process.env.NODE_ENV checks.
|
|
159
|
-
* Webpack/esbuild replaces process.env.NODE_ENV statically at build time,
|
|
160
|
-
* so these are zero-cost — they tree-shake correctly in both client and server bundles.
|
|
161
157
|
*/
|
|
162
|
-
/** True only in
|
|
158
|
+
/** True only in next dev / jest / vitest */
|
|
163
159
|
declare const isDevelopment: boolean;
|
|
164
|
-
/** True in
|
|
160
|
+
/** True in any non-development environment */
|
|
165
161
|
declare const isProduction: boolean;
|
|
166
|
-
/** Package version
|
|
162
|
+
/** Package version */
|
|
167
163
|
declare const MONITOR_VERSION: string;
|
|
168
164
|
|
|
169
165
|
/**
|
package/dist/client.mjs
CHANGED
|
@@ -496,7 +496,7 @@ var NetworkError = _NetworkError;
|
|
|
496
496
|
// src/_api/generated/cfg_monitor/logger.ts
|
|
497
497
|
import { createConsola } from "consola";
|
|
498
498
|
var DEFAULT_CONFIG = {
|
|
499
|
-
enabled:
|
|
499
|
+
enabled: process.env.NODE_ENV !== "production",
|
|
500
500
|
logRequests: true,
|
|
501
501
|
logResponses: true,
|
|
502
502
|
logErrors: true,
|
|
@@ -1339,9 +1339,9 @@ async function sendBatch(batch, useBeacon = false) {
|
|
|
1339
1339
|
__name(sendBatch, "sendBatch");
|
|
1340
1340
|
|
|
1341
1341
|
// src/client/utils/env.ts
|
|
1342
|
-
var isDevelopment =
|
|
1343
|
-
var isProduction =
|
|
1344
|
-
var MONITOR_VERSION = "2.1.
|
|
1342
|
+
var isDevelopment = process.env.NODE_ENV === "development";
|
|
1343
|
+
var isProduction = !isDevelopment;
|
|
1344
|
+
var MONITOR_VERSION = "2.1.235";
|
|
1345
1345
|
|
|
1346
1346
|
// src/client/store/index.ts
|
|
1347
1347
|
var CIRCUIT_BREAKER_THRESHOLD = 3;
|