@coralogix/browser 3.1.0 → 3.2.0
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/CHANGELOG.md +10 -0
- package/README.md +1 -1
- package/index.esm2.js +25 -11
- package/package.json +1 -1
- package/src/tools/getZoneJsOriginalDom.d.ts +0 -5
- package/src/utils/zone-patch.d.ts +10 -0
- package/src/version.d.ts +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
package/index.esm2.js
CHANGED
|
@@ -593,9 +593,9 @@ var CoralogixErrorInstrumentation = (function (_super) {
|
|
|
593
593
|
};
|
|
594
594
|
CoralogixErrorInstrumentation.prototype.reportError = function (source, err, customData, labels) {
|
|
595
595
|
return __awaiter(this, void 0, void 0, function () {
|
|
596
|
-
var message, name, span, cleanMessage;
|
|
597
|
-
return __generator(this, function (
|
|
598
|
-
switch (
|
|
596
|
+
var message, name, span, cleanMessage, supportMfe;
|
|
597
|
+
return __generator(this, function (_b) {
|
|
598
|
+
switch (_b.label) {
|
|
599
599
|
case 0:
|
|
600
600
|
message = err.message, name = err.name;
|
|
601
601
|
span = this.createSpan('error');
|
|
@@ -610,9 +610,16 @@ var CoralogixErrorInstrumentation = (function (_super) {
|
|
|
610
610
|
if (labels) {
|
|
611
611
|
setCustomLabelsForSpan(span, labels);
|
|
612
612
|
}
|
|
613
|
+
supportMfe = getSdkConfig().supportMfe;
|
|
614
|
+
if (!supportMfe) return [3, 2];
|
|
613
615
|
return [4, buildStacktrace(span, err)];
|
|
614
616
|
case 1:
|
|
615
|
-
|
|
617
|
+
_b.sent();
|
|
618
|
+
return [3, 3];
|
|
619
|
+
case 2:
|
|
620
|
+
void buildStacktrace(span, err);
|
|
621
|
+
_b.label = 3;
|
|
622
|
+
case 3:
|
|
616
623
|
span.end();
|
|
617
624
|
return [2];
|
|
618
625
|
}
|
|
@@ -621,20 +628,27 @@ var CoralogixErrorInstrumentation = (function (_super) {
|
|
|
621
628
|
};
|
|
622
629
|
CoralogixErrorInstrumentation.prototype.reportString = function (source, message, stackError) {
|
|
623
630
|
return __awaiter(this, void 0, void 0, function () {
|
|
624
|
-
var span;
|
|
625
|
-
return __generator(this, function (
|
|
626
|
-
switch (
|
|
631
|
+
var span, supportMfe;
|
|
632
|
+
return __generator(this, function (_b) {
|
|
633
|
+
switch (_b.label) {
|
|
627
634
|
case 0:
|
|
628
635
|
span = this.createSpan(source);
|
|
629
636
|
addErrorDefaultAttributes(span);
|
|
630
637
|
span.setAttribute(CoralogixAttributes.SOURCE, source);
|
|
631
638
|
span.setAttribute(ErrorAttributes.MESSAGE, message === null || message === void 0 ? void 0 : message.substring(0, MESSAGE_LIMIT));
|
|
632
|
-
|
|
639
|
+
supportMfe = getSdkConfig().supportMfe;
|
|
640
|
+
if (!stackError) return [3, 4];
|
|
641
|
+
if (!supportMfe) return [3, 2];
|
|
633
642
|
return [4, buildStacktrace(span, stackError)];
|
|
634
643
|
case 1:
|
|
635
|
-
|
|
636
|
-
|
|
644
|
+
_b.sent();
|
|
645
|
+
return [3, 3];
|
|
637
646
|
case 2:
|
|
647
|
+
void buildStacktrace(span, stackError);
|
|
648
|
+
_b.label = 3;
|
|
649
|
+
case 3:
|
|
650
|
+
_b.label = 4;
|
|
651
|
+
case 4:
|
|
638
652
|
span.end();
|
|
639
653
|
return [2];
|
|
640
654
|
}
|
|
@@ -4138,7 +4152,7 @@ function resolveUrlBlueprinters(urlBlueprinters) {
|
|
|
4138
4152
|
return resolvedUrlBlueprinters;
|
|
4139
4153
|
}
|
|
4140
4154
|
|
|
4141
|
-
var SDK_VERSION = '3.
|
|
4155
|
+
var SDK_VERSION = '3.2.0';
|
|
4142
4156
|
|
|
4143
4157
|
function shouldDropEvent(cxRumEvent, options) {
|
|
4144
4158
|
if (isDocumentErrorWithoutMessage(cxRumEvent)) {
|
package/package.json
CHANGED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export interface ZoneType {
|
|
2
|
+
root: ZoneType;
|
|
3
|
+
current: ZoneType;
|
|
4
|
+
__symbol__?: (name: string) => string;
|
|
5
|
+
run: <T>(fn: () => T) => T;
|
|
6
|
+
}
|
|
7
|
+
export declare function hasZoneJs(): boolean;
|
|
8
|
+
export declare function isInRootZone(): boolean;
|
|
9
|
+
export declare function runOutsideAngularZone<T>(fn: () => T): T;
|
|
10
|
+
export declare function patchAsyncApisForZone(): (() => void) | undefined;
|
package/src/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "3.
|
|
1
|
+
export declare const SDK_VERSION = "3.2.0";
|