HACKER Q&A
📣 hashedout

Easiest JavaScript front end framework for a back end dev?


Hello HN!

I'm a working as a NodeJS dev for past 2 years. I find working on frontend very tedious, this is the reason why I purchase themes as they already have custom components. For a personal project I've built the whole frontend using EJS to render HTML, the vanilla JS to do everything else.

I tried learning React but it was a steep learning curve for me. Now I want to convert the whole frontend app into a fast loading SPA. What framework is the easiest to learn?

So far I've run into these options: Svelte and VueJs.


  👤 xenopticon Accepted Answer ✓
Vue might have a similar learning curve as React if you are only used to Vanilla and template engines. Never really checked Svelte. Alpine.js [1] could be an option too.

[1] https://github.com/alpinejs/alpine


👤 skylark
If you're looking for something dead simple, I'd suggest Mithril. The API is tiny, but powerful, and will give you the tools you need to create reactive views that update to state changes.

The major downside to using highly unopinionated frameworks like Mithril is that the burden of project organization is on you. But since this is a personal project that you can use to learn FE development, I think it would be a good fit.


👤 runawaybottle
Honestly, just use JQuery. If you need a resume item, then just go React. A lot of what React offers on teams is that it makes it dead simple to make a reusable component. I’ll throw a rock at someone at work if they didn’t make the component sensibly reusable (takes obvious props, does one predictable thing, doesn’t take 50 props, etc - you know, the same kind of shit you’d expect of a good function, sane defaults, sane arity, sane output).

It’s hard to expect people to make a sane function, let alone a sane front end component. Before React, our expectations were zero in this space. If you care about these things, invest the time and learn React. If not, jquery is more than enough to build the most robust modern ui that will be performant. In other words, show me the most advanced/performant user interface you see on the internet today and I’ll show you how to do it with jquery (you have my word on this).


👤 g5becks
Svelte, by a large margin imo.

👤 fiftyacorn
Try react but nextjs. I find it conceptually easier

👤 bnt
Both! I find Vue easier because it feels more like the old days of jQuery and AngularJS (HTML templates etc).