-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
chore(deps): Remove tslib dependency
#5753
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
Conversation
tslib to dev dependenciestslib dependency
AbhiPrasad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ff9f812 to
df03535
Compare
size-limit report 📦
|
4731ed6 to
a298135
Compare
a298135 to
d31eee9
Compare
|
This pull request has gone three weeks without activity. In another week, I will close it. But! If you comment or otherwise update it, I will reset the clock, and if you label it "A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀 |
|
🥺 |
|
Maybe one day we'll get back to this, but it might be easier to try upgrading TS before we do. |
NOTE: Though most of the the problems the change causes have been solved, I'm leaving this in draft form until I can figure out why the
tracePropogationTargetstests (and only thetracePropogationTargetstests) consistently fail. Very mysterious...Now that we use Sucrase and Rollup for transpiling in our main build process, we no longer need
tslibas a runtime dependency. (Sucrase and Rollup have their own ES6 polyfills, which we vendor.)We do still use
tscwhen creating ES5 bundles, but we do so throughrollup-plugin-typescript-2, which includestslibamong its own dependencies.We've also been using it (indirectly) in our tests.
ts-jestworks by transpiling relevant TS files on the fly before runningjest, and it's set to use the localtsconfig.test.jsonwhen it does so. Because all of our tsconfig files inherit from the tsconfig in@sentry/typescript, they've all been running withimportHelpersset totrue, which makes our testing dependent ontslib. But since we have no other reason to depend ontslib(and since we obviously don't care about bundle size when it comes to the temporary filests-jestcreates), it's fine to let TS just include the helper implementations alongside their use. Thus we can turnimportHelpersoff , which means we no longer needtslibas a direct dev dependency, either.This therefore removes it from our dependencies, both at the repo and package levels.
Notes:
The change to
importHelpersis done at the repo level, rather than being done directly in@sentry/typescript, because other packages (likesentry-capacitorandcraft, among others) also depend on@sentry/typescript(and use our old build infrastructure, which needed the setting).An old test testing for the inclusion of
tslibcode in our build files, and theskipFilessetting in one of ourlaunch.jsonprofiles have also been removed, as they are now moot.