Advices for minifying a TS library. #7960
Unanswered
RichardMoralesLuis
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey! I'm currently working on improve the build of my library. It is currently created on TS and I developed it for sharing some utilities between other projects of my company.
Now I'm using Webpack 5 and I would like to move it to SWC. After some tests the building is faster and I'm happy with the time but I have a concern with the minify. With Webpack 5 using
ts-loader
the output is only 175KB, but if I use SWC the output is 253KB, so maybe I'm doing something wrong.Could anyone help me with some advices?
Here is my .swcrc
.swcrc
And this is the script that I used for building the app.
build.sh
Note: I'm using TSC because I need to create the
.d.ts
filesIn the package.json I have
Thanks in advance! 😄
Beta Was this translation helpful? Give feedback.
All reactions