DEV Community

Cover image for Why I Ditched Babel for SWC—My Builds Are 400x Faster!
div foo
div foo

Posted on • Originally published at blog.div.foo

Why I Ditched Babel for SWC—My Builds Are 400x Faster!

I recently switched from Babel to SWC on a real production app, and the results were mind-blowing! My build time dropped from 91s to just 216ms, and my build size shrank from 27MB to 18MB. 🚀"

In my latest article, I break down why SWC is a game-changer and how it can supercharge your build speed.

Read the full story here.

Top comments (2)

Collapse
 
himanshu_code profile image
Himanshu Sorathiya

Same, I use vite, when I was learning react with typescript I started with vite, and always though why there's always option for js + swc and ts + swc, at that time after completing react learning, I researched on it, read many peoples review and tested myself and yes it was super fast and better compression.

For comparison I applied swc with prev made my biggest project ( at that time biggest ) and build with swc and comparatively smaller project with babel and surprisingly that bigger project with swc build was faster compared to smaller project with babel.

Just one down side of using swc is that it's community is still growing so there are not many plugins, but babel has way too many customization options with its vast ecosystem ( I knows most of people don't know about babel plugins eitherways ).

My best advice would be to start using SWC.

Collapse
 
divfoo profile image
div foo

Absolutely! SWC's speed is a game-changer, and your comparison nails it—faster builds on bigger projects. While Babel has more plugins, SWC's performance makes it worth the switch. Great advice! 🚀