Vanilla JavaScript is basically JavaScript without using libraries or frameworks like React, Angular, or Vue.js. Instead of using those frameworks, you’re relying only on the language itself and the basic (and not so basic) objects and functions available in the browser.

Those objects and functions that the browser provides is known as the Document Object Model (DOM).

The concept of Vanilla JavaScript is important because you can technically create applications without using frameworks. The thing is, if the application you’re trying to build is too complex, it will become too difficult to maintain.

That’s why frameworks are fantastic tools when you have to create a big application because they have simple interfaces to tasks that would be too complex if you just use Vanilla JS. Thanks to frameworks, you can create big apps in a maintainable way.

But the flip side is, frameworks add bloat to your project. Frameworks are big pieces of code and they can make your app load slower. So, what do you do?

In big applications, the advantages are bigger than the disadvantages. In those cases, the best thing to do is to use frameworks anyway.

However, if your application is small, just use Vanilla JavaScript, maintaining the code isn’t really hard in those cases.

Join the newsletter!

Front end dev doesn't have to be hard! Tips and articles to help you become a better front-end dev.

    We won't send you spam. Unsubscribe at any time.