posthog-js 1.32.3 → 1.33.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/dist/es.js CHANGED
@@ -881,7 +881,7 @@ var LZString = {
881
881
  }
882
882
  };
883
883
 
884
- var version = "1.32.3";
884
+ var version = "1.33.0";
885
885
 
886
886
  // e.g. Config.DEBUG = Config.DEBUG || instance.get_config('debug')
887
887
 
@@ -1641,6 +1641,11 @@ var _info = {
1641
1641
 
1642
1642
  return parseFloat(matches[matches.length - 2]);
1643
1643
  },
1644
+ browserLanguage: function browserLanguage() {
1645
+ return navigator.language || // Any modern browser
1646
+ navigator.userLanguage // IE11
1647
+ ;
1648
+ },
1644
1649
  os: function os() {
1645
1650
  var a = userAgent;
1646
1651
 
@@ -1716,6 +1721,7 @@ var _info = {
1716
1721
  $host: window.location.host,
1717
1722
  $pathname: window.location.pathname,
1718
1723
  $browser_version: _info.browserVersion(userAgent, navigator.vendor, window.opera),
1724
+ $browser_language: _info.browserLanguage(),
1719
1725
  $screen_height: window.screen.height,
1720
1726
  $screen_width: window.screen.width,
1721
1727
  $viewport_height: window.innerHeight,
@@ -4075,7 +4081,7 @@ var Decide = /*#__PURE__*/function () {
4075
4081
  console.error("Error while initializing PostHog app with config id ".concat(id), e);
4076
4082
  };
4077
4083
 
4078
- window["__$$ph_web_js_".concat(id)] = _this2.instance;
4084
+ window["__$$ph_site_app_".concat(id)] = _this2.instance;
4079
4085
  document.body.appendChild(script);
4080
4086
  };
4081
4087