Hacker News new | ask | show | jobs
by wambotron 4534 days ago
Plain JS is great! I love writing it.

That said, as a site (or app) grows, you generally end up writing more utility functions than you expected, and at some point it cancels out the benefits of NOT using jquery (or another lib). You have to weigh these decisions out, but saying "plain JS is better than jquery" is misleading since, in the end, jq is also written in plain JS. Think of it as all of those utility functions you DON'T have to write.

Just make sure you understand vanilla JS and I see no issues with leveraging libraries to make dev time faster. Those libs are generally tested enough to ensure cross-browser compatibility and save you the headache of rolling your own everywhere.

1 comments

An even better solution is to use something like component.io or browserify. Then you still write mostly plain javascript, but can pull in small components and utilities when needed.