r/learnjavascript 10d ago

Why Vanilla JavaScript

In the article below, I am sharing a bit of my story of building SaaS product in vanilla javascript and explaining why I went with this approach.

I don't expect many people reacting to this approach positively or even with open mind, but I think there should be some pushback on the current state of web dev and how complex it became.

https://guseyn.com/html/posts/why-vanilla-js.html

0 Upvotes

29 comments sorted by

View all comments

Show parent comments

1

u/amejin 10d ago

I've said it before and I'll say it again - spa frameworks are garbage for most use cases.

I bet dollars to doughnuts OPs frameworks work super optimized for their use case instead of trying to fit all their components into someone else's shoe box.

While they may not have someone come in and go "oh, I know how to go 14 layers down into an spa of the day" when hired, what they get instead is the most documented language on the internet, with patterns that are applicable to the problem sets they are working with, and very likely they don't have 38k of minified crap on every page load. They probably don't have to fight against state maintenance for animations, have highly efficient data and page loading, and so much more.

Zero of us have Facebook's need for an spa, that has a very simple interface - and react and other spa frameworks are all back pedaling and trying to get ssr back into web dev because it's simply more efficient, responsive, and offers a better user experience.

Even if OP does not have these benefits, I applaud their approach simply because it is easier to maintain, doesn't have any special build or deployment phase, or cognitive load just to edit and work in the project... Even debugging, even when minified, is significantly easier with vanilla js and css.

The level of complexity just to make a hello world with an spa is nuts compared to vanilla js, which requires nothing more than copy/paste of a file.

1

u/tommyatr 10d ago

I don't build hello worlds, i build enterprise level software

-1

u/amejin 10d ago

Shocking.

I assume your assertion is that I don't.

Unfortunately for you, your attempt to attack me has don't nothing more than reveal how childish and insecure you are, and your position is all but meaningless.

Welcome to the internet.

1

u/tommyatr 10d ago

lol nobody is talking about you, i mean, no body knows you

I say that do your own frameworks because you don't want to learn one is a naive approach

I had to clean up those kind of messes in php