Member-only story

In the last decade, we’ve seen the meteoric rise of JavaScript frameworks. From Angular to React, Vue to Ember, and a myriad of others, the modern web development landscape is filled with choices that offer a dizzying array of conveniences. These libraries promise to simplify your workflow, organize your code, and, ultimately, enhance your web development experience. And yet, I find myself passionately returning to the elegant simplicity of Vanilla JS.
To some, my preference may seem retrograde, even stubborn. How can I opt for an older model when so many state-of-the-art options await? Why would I write in the base language when there are countless frameworks specifically designed to streamline and accelerate the coding process?
This isn’t an obstinate rejection of progress, but rather a thoughtful appraisal of the advantages and drawbacks inherent in the varied incarnations of JavaScript.
The Bloat Issue
First, there’s the matter of bloat. The very design of modern JavaScript libraries carries an intrinsic heft. These frameworks often come bundled with a vast suite of tools and features, many of which may not be utilized in a given project. The inclusion of these unused features contributes to increased file sizes and, by extension, slower load times. This “bloat” can harm the user experience, particularly on slower connections or less powerful devices.
Contrast this with Vanilla JS, where you only write and include what’s necessary for the task at hand. The difference in performance might seem minuscule at first, but it’s a compounding problem. As we know, web users have an increasingly short patience for load times. The decision between a heavier library and leaner base code might be the difference between a user staying or bouncing off your site.
Control and Learning
Another compelling reason I’ve found for choosing Vanilla JS is the level of control it offers. Frameworks and libraries abstract a lot of processes, hiding the inner workings behind a simpler interface. While this is beneficial in some respects, it can also be limiting. It can potentially prevent developers from fully understanding what’s going on under the hood.