message: browser: Make TraceKit work as regular ES6 module
diff: @@ -6,15 +6,22 @@ import { isUndefined, isError, isErrorEvent } from '@sentry/utils/is';
  * This was originally forked from github.com/occ/TraceKit, but has since been
  * largely modified and is now maintained as part of Sentry JS SDK.
  *
  + * NOTE: Last merge with upstream repository
  + * Jul 11,2018 - #f03357c
  + *
  * https://github.com/csnover/TraceKit
  * @license MIT
  * @namespace TraceKit
  */
  -(function(window, undefined) {
  - if (!window) {
  - return;
  - }
  +var window =
  + typeof window !== 'undefined'
  + ? window
  + : typeof global !== 'undefined'
  + ? global
  + : typeof self !== 'undefined'
  + ? self
  + : {};
  var TraceKit = {};
  var _oldTraceKit = window.TraceKit;
  @@ -1134,9 +1141,7 @@ import { isUndefined, isError, isErrorEvent } from '@sentry/utils/is';
  item.func = guessFunctionName(item.url, item.line);
  }
  var context = gatherContext(item.url, item.line);
  - var midline = context
  - ? context[Math.floor(context.length / 2)]
  - : null;
  + var midline = context ? context[Math.floor(context.length / 2)] : null;
  if (
  context &&
  midline.replace(/^\s*/, '') === lines[line + 1].replace(/^\s*/, '')
  @@ -1289,11 +1294,7 @@ import { isUndefined, isError, isErrorEvent } from '@sentry/utils/is';
  var reference = / '([^']+)' /.exec(ex.message || ex.description);
  if (reference) {
  - item.column = findSourceInLine(
  - reference[1],
  - source.url,
  - source.line,
  - );
  + item.column = findSourceInLine(reference[1], source.url, source.line);
  }
  }
  @@ -1456,24 +1457,6 @@ import { isUndefined, isError, isErrorEvent } from '@sentry/utils/is';
  TraceKit.linesOfContext = 11;
  }
  - // UMD export
  - if (typeof define === 'function' && define.amd) {
  - define('TraceKit', [], TraceKit);
  - } else if (
  - typeof module !== 'undefined' &&
  - module.exports &&
  - window.module !== module
  - ) {
  - module.exports = TraceKit;
  - } else {
  - window.TraceKit = TraceKit;
  - }
  -})(
  - typeof window !== 'undefined'
  - ? window
  - : typeof global !== 'undefined'
  - ? global
  - : typeof self !== 'undefined'
  - ? self
  - : {},
  -);
  +const computeStackTrace = TraceKit.computeStackTrace;
  +
  +export { computeStackTrace };
  