Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change target in tsconfig to ES6 #1522

Merged
merged 1 commit into from
Jun 20, 2023
Merged

Conversation

bidoubiwa
Copy link
Contributor

By default, the target in a tsconfig is ES3. This ensures compatibility with environments that predates 2015. The downside of having this insurance is the size of the bundle.

By changing from ES3 to esnext we go from a bundle size of 108k to a bundle size of 60k.

Looking at what other libraries do, they seem to agree on using esnext as a target. While you might argue that it raises some risks, our library, like the other ones using esnext, is made to be used in modern environments.

@bidoubiwa bidoubiwa added the breaking-change The related changes are breaking for the users label Jun 19, 2023
Copy link
Member

@brunoocasali brunoocasali left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!!

@bidoubiwa
Copy link
Contributor Author

bors merge

@meili-bors
Copy link
Contributor

meili-bors bot commented Jun 20, 2023

Build succeeded:

@meili-bors meili-bors bot merged commit c919f08 into main Jun 20, 2023
@meili-bors meili-bors bot deleted the change_target_in_tsconfig branch June 20, 2023 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change The related changes are breaking for the users
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants