@sentry/browser
@sentry/node
raven-js
raven-node
_(raven for node)_5.0.6
Currently in 5x, there are multiple instances of functions being used that are not supported on IE. Object.assigns
, Array.prototype.includes
are obvious ones, but given the wide refactor of utils, i'm sure there are more.
In Supported Browsers you imply that IE is fully supported, however in the PRs for these changes you mention that the docs are going to need updating. :/
Previously, the related issues github is showing me demonstrate you've worked back to provide IE support. However, it does not appear that's the case going forward?
Can you confirm what version we should use that is both a: fully supported by sentry and b: fully supported in IE? OR, if polyfills are the way to go, could you ship / point to the set needed to support sentry?
thanks!
Hey, so I've updated the docs so they reflect that you should load the whole polyfill for older browser.
https://github.com/getsentry/sentry-docs/pull/886
You already had to polyfill promise before, we should have updated this earlier.
Depending on your setup this is mostly only relevant if you are using the CDN or Loader version, if you bundle your app yourself you need to take care to which support level you compile your bundle.
I hope this makes sense, thanks.
@HazAT Correct me if I'm wrong, but the Polyfill.io bundle (referenced in https://github.com/getsentry/sentry-docs/pull/886) includes polyfills for much more than what's required by the browser bundle. For example, the IE11 bundle is >42 KB. Adding 42KB of scripts just to migrate from v3/v4 of the browser bundle to v5 seems overkill.
If you don't want to include the polyfills in the Browser bundle itself, would it be possible to at least document the specific features that must be polyfilled? That way, we could cherry-pick specific polyfills that are needed by Sentry itself, and it would also enable us to exclude polyfills that are already included by us for other reasons.
@USSRLivesOn We will update the docs to list which Polyfills are required.
@USSRLivesOn It's
https://polyfill.io/v3/polyfill.min.js?features=Promise%2CObject.assign%2CString.prototype.includes
So Promise
, Object.assign
and String.prototype.includes
Will update our docs.
@HazAT Thank you! That's perfect.
@HazAT to me this is absolutely crazy that we would be required to load a synchronous script tag in the head. Sentry script is already quite heavy / slow and we came up with an async loading solution and just discovered that our errors weren't being surfaced after migrating to 5.1.1
. I would suggest offering a solution that support older browsers without polyfills. Doesn't seem like too hard of a lift to do that
I'm getting this since 5.5.0 in IE11
"TypeError: Object doesn't support property or method 'assign'
at n.prototype.K (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:18837)
at n (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:18357)
at n (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:19428)
at n (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:34854)
at e (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:35441)
at e.prototype.pn (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:36082)
at n (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:25347)
at e (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:35891)
at n (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:21500)
at t (https://browser.sentry-cdn.com/5.5.0/bundle.min.js:2:37558)"
Having waited ages for an async method which greatly improved our pagespeed audits, I'm not particularly thrilled to have a sync script in the head.
And since your support table includes IE10/11, the base script should be enough to have proper support.
Have you ever considered doing what Google Fonts does? It serves script via User Agent, so the latest Chrome gets a non-polyfill file and so on and so on till IE11 which would be fully polyfilled.
@dalyr95 the table indeed includes IE, but it also has a huuuge orange box saying what polyfills it requires - https://docs.sentry.io/platforms/javascript/#browser-table
IE10/11 have small enough usage for us, that adding it to the main bundle would increase it's size for no real reason.
I probably posted this in the wrong project, but you want us to connect to a third 3rd party domain in an sync manner is too much. https://github.com/getsentry/sentry/issues/13783
When submitting to NPM atm, you're advised strongly to not provide es6 code and supple transpiled code. Considering the whole amount of browsers your code will run on, providing consistency would be an advantage.
Hi @kamilogorek looks like 5.7.0 no longer needs polyfills and the browser table says you only need them if using <5.7.0. Is this the case? Brilliant work if so.
https://github.com/getsentry/sentry-javascript/releases/tag/5.7.0
[browser] ref: Remove all required IE10-11 polyfills
[browser] ref: Remove Object.assign method usage
[browser] ref: Remove Number.isNaN method usage
[browser] ref: Remove includes method usage
@dalyr95 that is correct :) thanks!
Most helpful comment
@dalyr95 that is correct :) thanks!