@microsoft/applicationinsights-web-basic 2.8.8-nightly.2209-01 → 2.8.8-nightly.2209-03

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.
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Microsoft.ApplicationInsights, 2.8.8-nightly.2209-01
2
+ * Microsoft.ApplicationInsights, 2.8.8-nightly.2209-03
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  *
5
5
  * Microsoft Application Insights Team
@@ -1232,6 +1232,18 @@ declare namespace ApplicationInsights {
1232
1232
  * Specifies the path to use for the cookie, defaults to '/'
1233
1233
  */
1234
1234
  path?: string;
1235
+ /**
1236
+ * Specify the cookie name(s) to be ignored, this will cause any matching cookie name to never be read or written.
1237
+ * They may still be explicitly purged or deleted. You do not need to repeat the name in the `blockedCookies`
1238
+ * configuration.(Since v2.8.8)
1239
+ */
1240
+ ignoreCookies?: string[];
1241
+ /**
1242
+ * Specify the cookie name(s) to never be written, this will cause any cookie name to never be created or updated,
1243
+ * they will still be read unless also included in the ignoreCookies and may still be explicitly purged or deleted.
1244
+ * If not provided defaults to the same list provided in ignoreCookies. (Since v2.8.8)
1245
+ */
1246
+ blockedCookies?: string[];
1235
1247
  /**
1236
1248
  * Hook function to fetch the named cookie value.
1237
1249
  * @param name - The name of the cookie
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * Application Insights JavaScript Web SDK - Basic, 2.8.8-nightly.2209-01
2
+ * Application Insights JavaScript Web SDK - Basic, 2.8.8-nightly.2209-03
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  (function (global, factory) {
@@ -1537,7 +1537,7 @@
1537
1537
  }
1538
1538
 
1539
1539
  var _objDefineProperty = ObjDefineProperty;
1540
- var version = "2.8.8-nightly.2209-01";
1540
+ var version = "2.8.8-nightly.2209-03";
1541
1541
  var instanceName = "." + newId(6);
1542
1542
  var _dataUid = 0;
1543
1543
  function _createAccessor(target, prop, value) {
@@ -1652,6 +1652,20 @@
1652
1652
  }
1653
1653
  return cookieMgrCfg;
1654
1654
  }
1655
+ function _isIgnoredCookie(cookieMgrCfg, name) {
1656
+ if (name && cookieMgrCfg && isArray(cookieMgrCfg.ignoreCookies)) {
1657
+ return cookieMgrCfg.ignoreCookies[_DYN_INDEX_OF$1 ](name) !== -1;
1658
+ }
1659
+ return false;
1660
+ }
1661
+ function _isBlockedCookie(cookieMgrCfg, name) {
1662
+ if (name && cookieMgrCfg && isArray(cookieMgrCfg.blockedCookies)) {
1663
+ if (cookieMgrCfg.blockedCookies[_DYN_INDEX_OF$1 ](name) !== -1) {
1664
+ return true;
1665
+ }
1666
+ }
1667
+ return _isIgnoredCookie(cookieMgrCfg, name);
1668
+ }
1655
1669
  function createCookieMgr(rootConfig, logger) {
1656
1670
  var _a;
1657
1671
  var cookieMgrConfig = _createCookieMgrConfig(rootConfig || _globalCookieConfig);
@@ -1673,7 +1687,7 @@
1673
1687
  },
1674
1688
  _a.set = function (name, value, maxAgeSec, domain, path) {
1675
1689
  var result = false;
1676
- if (_isMgrEnabled(cookieMgr)) {
1690
+ if (_isMgrEnabled(cookieMgr) && !_isBlockedCookie(cookieMgrConfig, name)) {
1677
1691
  var values = {};
1678
1692
  var theValue = strTrim(value || STR_EMPTY);
1679
1693
  var idx = theValue[_DYN_INDEX_OF$1 ](";");
@@ -1716,7 +1730,7 @@
1716
1730
  },
1717
1731
  _a.get = function (name) {
1718
1732
  var value = STR_EMPTY;
1719
- if (_isMgrEnabled(cookieMgr)) {
1733
+ if (_isMgrEnabled(cookieMgr) && !_isIgnoredCookie(cookieMgrConfig, name)) {
1720
1734
  value = (cookieMgrConfig.getCookie || _getCookieValue)(name);
1721
1735
  }
1722
1736
  return value;
@@ -4278,6 +4292,9 @@
4278
4292
  else if (window && window["opera"] && errorObj[strMessage]) {
4279
4293
  details = _getOperaStack(errorObj[_DYN_MESSAGE ]);
4280
4294
  }
4295
+ else if (errorObj["reason"] && errorObj.reason[strStack]) {
4296
+ details = _convertStackObj(errorObj.reason[strStack]);
4297
+ }
4281
4298
  else if (isString(errorObj)) {
4282
4299
  details = _convertStackObj(errorObj);
4283
4300
  }
@@ -5063,7 +5080,7 @@
5063
5080
  }
5064
5081
  }
5065
5082
  var EnvelopeCreator = {
5066
- Version: "2.8.8-nightly.2209-01"
5083
+ Version: "2.8.8-nightly.2209-03"
5067
5084
  };
5068
5085
  function DependencyEnvelopeCreator(logger, telemetryItem, customUndefinedValue) {
5069
5086
  EnvelopeCreatorInit(logger, telemetryItem);