Live data from Hacker News

Vue RFC: Expose logic-related component options via function-based APIs instead

github.com

71–80 of 253 posts

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#72
post #9

I've been following the Vue + TypeScript progress on and off for the past couple years (ever since I converted a React project to Vue and threw out TS in the process, since it was just so fundamentally incompatible with Vue's APIs). This is a pretty wild change compared to the now-abandoned class proposal, and I'm somewhat bummed by it, but I'll admit that's mostly due to my continued skepticism of hooks (as someone…

I really disliked the function API and felt the class API with decorators was much easier to read and work on.. I'm pretty sad they are doubling down on function API and, apparently, ditching the class API?

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#73
post #65
post #16

I might be totally and completely wrong, but changing everything does not help anyone except scratch the itch of the framework's designers. I'm pretty sure this is all with the best intentions, but this would be a disaster similar to how Angular suddenly changed everything . Not against change, but the API is fine. Just iterate and evolve it. disclaimer: Big fan of Vue, early user and conference attender..

Couldn’t agree more, this is the reason I bailed on Angular. Not smart.

“Yes but I’m only considering Vue because Angular already screwed the last project I used it on”

What the hell.

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#74
post #16

I might be totally and completely wrong, but changing everything does not help anyone except scratch the itch of the framework's designers. I'm pretty sure this is all with the best intentions, but this would be a disaster similar to how Angular suddenly changed everything . Not against change, but the API is fine. Just iterate and evolve it. disclaimer: Big fan of Vue, early user and conference attender..

While I don't disagree about the fact it will likely cause a split similar to Angular, they seem quite explicit about the reasons (not to scratch the itch of the framework's designers). For me, working in a large project with TypeScript vs one in vanilla JavaScript makes all the difference in terms of how maintainable it is. The number and the nature of the tests I need to write for such project changes, the IDE tool…

My quip about scratching the designer’s itch is mostly about the following.

99% of people that got into Vue.js use it because it felt like an anti of the ever changing, dragon chasing JS world.

Changing the syntax will almost certainly yield zero benefits to the folks out in the field running apps for their businesses. They will end up with the same app, with the same functionality, just $100k lighter due to hours burnt on refactoring to the “function based” API.

Everyone roles their eyes and the bad wrap Javascript has continues.

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#75
It's important to note that this is an RFC for 3.x, and they seem to want to provide it for a 2.x revision, and provide a compatibility build, so it's not like angular 2+ where there's no real migration path.

If you have comments, this is where to tell the vue team: https://github.com/vuejs/rfcs/pull/42

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#76
post #66

Earlier quoted context omitted.

Well, with React you can "opt in" when searching by simply adding "hooks" to the search term. Such wasn't possible with Angular back then

Since the majority of the community will probably be using hooks from now on it will be assumed that is the default React methodology which will break books, talks, blog posts, SO answers, etc.

You can mix-and-match. If you want to write an individual component as a class you can, and if you want to later convert it to using hooks there's nothing stopping you.

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#77

Quick reminder that you can still write complex and useful form-driven web applications with no JavaScript at all.

This. I've used React and to my surprise even liked it, but if you have to start all over every 3 years, you've got to ask whether pulling your model ... whatever over to the client is actually worth it in the vast majority of cases. What was wrong with SSR and a bit of jquery and Ajax again?

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#78
post #46
post #16

I might be totally and completely wrong, but changing everything does not help anyone except scratch the itch of the framework's designers. I'm pretty sure this is all with the best intentions, but this would be a disaster similar to how Angular suddenly changed everything . Not against change, but the API is fine. Just iterate and evolve it. disclaimer: Big fan of Vue, early user and conference attender..

> this would be a disaster similar to how Angular suddenly changed everything. To be fair to Angular, if they'd stuck with what they had, it'd have faded into obscurity far more than the current version has. Angular.js was great for its time, but lost most of its advantages as the web caught up, and what used to be its advantages started to become kludges.

Im still om angularjs. Cant bother to learn new frameworks every other month. Also using Angularjs in recent projects i never ever thought I was hobbled. Angularjs,jquery,vue - doesnt matter which tool one use. If you know any of these at advanced level you can create anything

Re: Vue RFC: Expose logic-related component options via function-based APIs instead

#80
Python 3 vibes. Terrible decision. Our team has decided after seeing this to use Vue 2.x until we can move away from Vue. Extremely disappointed. Simplicity was Vue’s bread and butter. Literally the only reason to use it over React. Now what’s the point? We get it, you’re a smart guy who likes FP, quit punishing the rest of us.
Post reply on HN