Live data from Hacker News

Vue.js 3

github.com

91–100 of 308 posts

Re: Vue.js 3

#91
post #31

Good to see this out. I want to pick a good frontend scheme for future projects but I don't really need most of the fancy SPAs and the complexity coming with it. Invested a few weeks on Vue a few months back, then the concern about 'React has 80% market share and you can find React developer much more easily in the west" never went away. Maybe Mithril is the way out? I just need a really light-weight client-side-ajax…

So you suggest switching from one of the Big 3 to Mithril because you are concerned about market share, while Mithril probably has magnitudes less market share?

if i have to invest into one of the Big 3 then market-share becomes a concern, each of them requires quite some time and efforts to master, and you normally don't have enough extra time to switch after a while.

if I pick less known but easier-to-learn-got-job-done option I expect to invest less efforts, thus market-share is less critical for the concerns.

Re: Vue.js 3

#92
post #59

Earlier quoted context omitted.

I would neither need jQuery nor a templating engine to write Minesweeper.

It's great you applied your vanilla JS skills to his totally metaphorical example. I still don't get why it's okay for every other programming language to use the STL or huge dependencies, but doing so with javascript is frowned upon for some people. You wouldn't write a JSON parser yourself in CPP, you'd install something from conan or use the STL or boost for that. Why is it so bad to do the same with js?

The browser does supply a huge number of APIs.

To set one of the Minesweeper tiles to bomb, you could do:

tiles[x][y].className='bomb';

And you are done. The rendering will nicely take place according to what you defined in the CSS.

Re: Vue.js 3

#93
post #38

I still don't see a reason why one would use Vue or React. I agree that templating of data is something you should use a library for. But there are great templating libraries. Handlebars for example. Can someone give a short example of code that would be more elegant using Vue then just a simple template engine?

Any code involving a mid- to large sized web application that needs reactivity . Templating engines like handlebars are used on the server side, react and vue belong on the frontend (most of the time, but not exclusively). That's the reason people use them: If you want to, you can have your logic executed on the client-side only, and host whatever else you need on a cloud-provider. Client-Side computing doesn't scale…

Handlebars works nicely clientside.

Re: Vue.js 3

#94

if this means no more Vuex, i'm all for that. that extra abstraction layer never proved useful to me.

Out of curiosity, how do you handle data needed by tons of components at different tree depths (info about the current user for example)?

I don’t always reach for Vuex, but when an app reaches a certain size it sure beats passing every bit of common data down through the entire tree, as I find you quickly hit a point where you’re passing data to components solely so it can pass it to it’s children.

Re: Vue.js 3

#95

Earlier quoted context omitted.

> What if there's another new sexy JS framework in the future? That's how a market works. It's a strong incentive to keep Vue sexy.

The market also isn't as volatile as people make it out to be. The top most used js frameworks (React, Angular and Vue) have been in the top spots for 5 to 7 years now. I guess the market might as well be settled. Of course there are some new comers every year, but they don't enjoy a large market share. Hell, I've not even seen VueJS used once in any serious project in the industry. React and Angular are here to stay…

WTF are you talking about... so you don't consider any of these to be serious? sentry.io, Gitlab, Grammarly, Codeship, Behance

Re: Vue.js 3

#96
post #12
post #10

Earlier quoted context omitted.

I didn't expect him to say "Enjoy the Vue" ha.

Programmer and dad-level humor can be a pretty deadly combination.

The combination of the two is so dangerous you could say it's dadly.

Re: Vue.js 3

#97
post #49
post #38

I still don't see a reason why one would use Vue or React. I agree that templating of data is something you should use a library for. But there are great templating libraries. Handlebars for example. Can someone give a short example of code that would be more elegant using Vue then just a simple template engine?

It's almost a necessity for complicated apps. Right now I'm building an app which involves a reporting screen with all the following features on a single page: - 10+ breakdowns for report - 10+ filters for report - Each filter has an include/exclude dropdown list which then has multiple features within even a single filter (so some filters are EQUALS/NOT EQUALS) others are INCLUDES/DOESNT INCLUDE/EMPTY/NOT EMPTY and…

Nothing you describe is easier solved with Vue then with a templating engine.

You can have a "DropdownMenu" template, feed it the data (which you call "state") and update the according element on screen just fine.

Re: Vue.js 3

#98

Earlier quoted context omitted.

> What if there's another new sexy JS framework in the future? That's how a market works. It's a strong incentive to keep Vue sexy.

The market also isn't as volatile as people make it out to be. The top most used js frameworks (React, Angular and Vue) have been in the top spots for 5 to 7 years now. I guess the market might as well be settled. Of course there are some new comers every year, but they don't enjoy a large market share. Hell, I've not even seen VueJS used once in any serious project in the industry. React and Angular are here to stay…

Angular seems to be dying. Svelte is an interesting contender. I think it will be React's main competitor given a year or two.

Re: Vue.js 3

#99
post #4

I am impressed how they redesigned both internal architecture and a public API while keeping the users happy. Many well written projects fall into the trap of being a great fit for the contemporary practices but become less relevant over time as the ecosystem changes. Well done, Vue!

curious how easy it will be to move from vue 2 to vue 3

They're working on a "migration build" which is a version of v3 that has support for v2 behaviors + warnings, which should help smooth any transition.

On top of that, v2.7 slated for 2021Q1 also includes the relevant migration warnings, which should help make life easier

Re: Vue.js 3

#100
post #31

Good to see this out. I want to pick a good frontend scheme for future projects but I don't really need most of the fancy SPAs and the complexity coming with it. Invested a few weeks on Vue a few months back, then the concern about 'React has 80% market share and you can find React developer much more easily in the west" never went away. Maybe Mithril is the way out? I just need a really light-weight client-side-ajax…

AlpineJS? A bit polarizing, but definitely lightweight...

Alpine is great for the niche it fills. All the stuff where I used to say “Vue would be overkill for this, I’ll just throw something together with jQuery”, I now use Alpine for instead, and it’s a much nicer experience. And at 7kb you can’t really grumble.
Post reply on HN