Skip to content

[Bug]: Breaking change in alpha 2.0.0-alpha.15: ES2019 syntax #1592

Open
@jakewski

Description

@jakewski

Preflight Checklist

  • I have searched the issue tracker for a bug report that matches the one I want to file, without success.

What package is this bug report for?

rrweb

Version

2.0.0-alpha.15

Expected Behavior

rrweb should work for browsers that do not support optional catch binding https://2ality.com/2017/08/optional-catch-binding.html. The compatibility note in the readme states that rrweb should work for browsers that support the MutationObserver API https://2ality.com/2017/08/optional-catch-binding.html. I did not check for other breaking changes, but possible there are

Actual Behavior

rrweb imports have ES2019 syntax which breaks old compatibility

prior to 2.0.0-alpha.15 the rrweb source code also had optional catch binding but was compiled to be more compatible in the dist files.

Steps to Reproduce

  1. install rrweb via npm
  2. see the main rrweb module entrypoints contain ES2019 syntax (rrweb.js, rrweb.cjs)

Testcase Gist URL

No response

Additional Information

No response

Metadata

Metadata

Assignees

Labels

2.0bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions