Live data from Hacker News

Vue 3.2

blog.vuejs.org

51–60 of 153 posts

Re: Vue 3.2

#51

Anyone moved from React to Vue. I've been reading the Vue docs and I like some things about it but the compositional model seems a bit more confusing compared to React. Also, I think I do prefer working with JSX versus using html templates. I prefer that close coupling of JS logic and JSX presentation. The most appealing thing about Vue is that it seems to be more of a framework, maybe somewhere in the middle between…

I’m not a full-time front end developer, so take this with a grain of salt. I write JS frontends for my nights and weekends side projects. I chose Vue over React because it seemed easier to get up to speed.

When I was looking to change jobs earlier this year I spoke with a lot of recruiters and they all said companies were looking for React developers, there were zero mentions of Vue. I don’t really regret my choice of learning Vue but React would have definitely been a selling point on my resume.

Will this change in a few years? Who knows. It feels like it’s React vs everyone else and as more and more projects get built in React I suspect the difference will widen even more.

Re: Vue 3.2

#52

Anyone moved from React to Vue. I've been reading the Vue docs and I like some things about it but the compositional model seems a bit more confusing compared to React. Also, I think I do prefer working with JSX versus using html templates. I prefer that close coupling of JS logic and JSX presentation. The most appealing thing about Vue is that it seems to be more of a framework, maybe somewhere in the middle between…

For me JSX vs HTML templates depends of your organization and workflow. If you’re a solo dev or in a JS heavy team, I think JSX can make more sense. HTML templates on other hand give a lot of power to non dev. It works well for our agency with our web designers, they can handle all the logic in the HTML, so much that on some projects no additional JS developper is needed.

Re: Vue 3.2

#53

Anyone moved from React to Vue. I've been reading the Vue docs and I like some things about it but the compositional model seems a bit more confusing compared to React. Also, I think I do prefer working with JSX versus using html templates. I prefer that close coupling of JS logic and JSX presentation. The most appealing thing about Vue is that it seems to be more of a framework, maybe somewhere in the middle between…

We moved from Vue to React because it has much better static typing support. Properties are native Typescript values and templates are TSX which gives you proper Typescript type checking and also full IDE support (autocomplete, go to definition, etc.).

Also Vue's automatic reactivity system is fine for small websites but for large apps it turns into an impossible to follow spaghetti nightmare.

Re: Vue 3.2

#54

Anyone moved from React to Vue. I've been reading the Vue docs and I like some things about it but the compositional model seems a bit more confusing compared to React. Also, I think I do prefer working with JSX versus using html templates. I prefer that close coupling of JS logic and JSX presentation. The most appealing thing about Vue is that it seems to be more of a framework, maybe somewhere in the middle between…

What about security and upgrading?

I've heard there is some pain upgrading Vue, but there is definitely pain when upgrading React.

At the moment one of our previous React projects "npm install" gives 4000 security issues.

Re: Vue 3.2

#55
post #54

Anyone moved from React to Vue. I've been reading the Vue docs and I like some things about it but the compositional model seems a bit more confusing compared to React. Also, I think I do prefer working with JSX versus using html templates. I prefer that close coupling of JS logic and JSX presentation. The most appealing thing about Vue is that it seems to be more of a framework, maybe somewhere in the middle between…

What about security and upgrading? I've heard there is some pain upgrading Vue, but there is definitely pain when upgrading React. At the moment one of our previous React projects "npm install" gives 4000 security issues.

Having used React for well over 5 years, I have no idea which upgrade pain you are referring to?

Re: Vue 3.2

#56
post #24

We've been pretty happy with Vue 2.6 and haven't had the motivation to take the leap. I did try it and even though it's advertised as somewhat backward compatible it did break lots of things, which was totally expected and it's a major release. Also we couldn't figure out a lot of things, like how can I access the $children like before, why does everything show Object proxy in console, etc. Posting on SO and forums a…

When I am just yet another dev in the team, I use whatever the FE team decided upon, however on my own projects I use Web Components with lithtml. The browser underlying stack is always going to be there regardless of what is fashionable to wrap around it.

That’s not necessarily a belief that holds true universally. Plenty of developers have found that React and JSX are two technologies that have beautifully matured outside of their initial home in the web browser ecosystem.

To use your phrasing, React and JSX are always going to be there regardless of what is fashionable for them to be wrapped around.

Re: Vue 3.2

#57
I really wonder if all developers that really like jsx + inline grapql aren't old school php4 developers that were writing php logic and sql queries in the view itself.

Re: Vue 3.2

#58
post #4

I just started cobbling together a demo jquery app mess into a vue3 app yesterday, and lemme tell ya, the docs are great, and I even got from 0 to VueX in few hours today. I'm impressed. Great work Vue team. I'm normally hesitant to adopt a new version of a library when learning and expected to get bitten by a few more things but so far seems mature, stable, and well done. Edit: That said, I'm still personally not in…

I had much the same experience as you some 4 years ago. The exception was that I was heavily into Angular1 so Vue felt completely natural. The one page vue file made a lot of sense to me off the bat, sort of implying that the component is a singular "encapsulated" entity, at least thats my own mental model. Turns out it was completely wrong but it worked.

Isn't it basically encapsulated except the ?

The style requires you a `scoped` to opt in isolation with element created by other component.

Which always make me wonder about why such default is selected.

Re: Vue 3.2

#59

I think my favourite thing about Vue 3 and the composition API is that VueX is essentially obsolete - you can manage your global state by calling real life functions. This means instead of doing `dispatch("action")` you just call `action()`. When using Typescript this is a godsend, as the action functions keep all of their type information.

I recently found Pinia[1] as replacement for vuex. - full typing - real life functions - vue dev plugin support in store section - mutations don't exist as separate idea - also has api, so i wrote little plugin for state synchronization with local storage. *Typography fix 1. https://pinia.esm.dev/

Wow. That's exactly what I thought Vuex would look like after after the Vue 3 release.

Definitely going to use it for my future project.

Re: Vue 3.2

#60
post #5

Earlier quoted context omitted.

https://github.com/yyx990803/vue-svelte-size-analysis

It's weird for this analysis to focus on the total size of the app. If a Svelte app has 100 components but a page only uses 10, then surely it's possible to only fetch these 10 components and defer the rest, right? This way the size of each page does not have to grow linearly with the size of the app. And the size of each page matters more than the total size of the app -- after all, we're on the web, not on mobile w…

Considering the cut off point being very close to 10 (small components) - it all comes down to that Svelte, in practice, doesn't have any (significant) advantage bundle size wise.
Post reply on HN