Live data from Hacker News

Vue.js vs. React

vuejs.org

141–150 of 486 posts

Re: Vue.js vs. React

#141

Elm is also promising: http://www.oreilly.com/web-platform/free/files/why-elm.pdf

I'm using react and like its functional approaches. I started implementing libraries such as immutablejs, recompose and ramda. I also make use of pure functional components exclusively. Then I had a look at Elm and I realized that, with all the libraries I have put together, I created my own crippled frankenstein'ish version of Elm. I think I really should give Elm a try!

Re: Vue.js vs. React

#142
I don't know why inferno isn't more popular, I use a lot of html5 apis so for what I'm working on inferno is more useful to me than react or Vue. I'm doing webaudio so react native doesn't help me. Also inferno doesn't require me to enter into a patent agreement with Facebook and yet I get all the benefits of react from using inferno. Now if I were needing to use native APIs then I might need react native but then you have to balance that need with the potential license issues

Re: Vue.js vs. React

#143
post #84

These are the things I find to be killer features of React and it's ecosystem: - React Native (I know there's Weex but it's not production ready, nor as feature rich) - Streaming server side rendering - React Relay (GraphQL integration) - JSX by default . VueJS pushes an Angular-esque template language where I have to learn new syntax, binding concepts, directives and conditional statements. - Corporate backing I've…

> - Streaming server side rendering

This feature appeared in React v16 (which is still in beta). Vue had it long before.

Re: Vue.js vs. React

#144
I know this is about Vue vs React, but a lot of the things people are saying they like about Vue can be found in Google's Polymer. It's very simple to comprehend and you can make single file components. And it's based on W3C standard web components so you won't be building yourself into future obsolescence. With Polymer 2 components are now built using classes, so your code is clear and 100% native JS. Lastly, the goal of the Polymer team is to get rid of Polymer by advancing web standards, and with 2.0 you can see they are definitely following this approach as Polymer doesn't add much to web components other than ease of use functionality such as template binding and cross browser shims.

Re: Vue.js vs. React

#145
post #132

We moved away from React to Vue about 8 months ago and everyone on the team is a lot happier. First reason is we hate JSX. It forces you to write loops, conditionals, etc, outside of the markup you are currently writing/reading. It's like writing shitty PHP code without templates. It also forces you to use a lot of boilerplate like bind(), Object.keys(), etc. Another problem with React is that it only really solves o…

> First reason is we hate JSX. It forces you to write loops, conditionals, etc, outside of the markup you are currently writing/reading. It's like writing shitty PHP code without templates.

here here! This has been my experience as well

Re: Vue.js vs. React

#146

Earlier quoted context omitted.

i was in the same boat as you regards to syntax but in 10 mins you will grasp everything about vuejs. of all the frameworks, vuejs has the simplest syntax to learn. its no where as complex as angular and way more elegant. also beats jsx in terms of making your code more cleaner and prettier. im never going back to jsx.

Which part of this is clean or pretty? Button There are some redeeming qualities compared to say, Polymer. But it's neither clean nor pretty

You can make it cleaner:

   Button
   
   
   

Re: Vue.js vs. React

#147
post #127

One of the biggest things React has going for it, other than being maintained by Facebook and having a much larger community, is React Native. You can learn one web framework and now also make compelling, real native apps. To me those are both deal makers. Surprised I haven't seen this mentioned more in the thread.

I agree, there are many competitors to React for targeting the DOM, but there is much less competition for targeting Native. I hope to see more JSX-to-Native engines pop up soon to solve that problem.

Re: Vue.js vs. React

#148

i sense there may be a flood of react devs switching to vuejs. once their react projects are finished. honestly react devs are missing out on how great the vue experience is. it didnt take me too long to see how much better vue is.

I would say that experience-defining tools are webpack-dev-server with hot reload, ability to use modern ES features and type definitions via TypeScript or Babel+Flow.

These are available for both Vue and React. Is there something on top of that available for Vue?

Re: Vue.js vs. React

#149

I know this is about Vue vs React, but a lot of the things people are saying they like about Vue can be found in Google's Polymer. It's very simple to comprehend and you can make single file components. And it's based on W3C standard web components so you won't be building yourself into future obsolescence. With Polymer 2 components are now built using classes, so your code is clear and 100% native JS. Lastly, the go…

I've used polymer and I wasn't impressed. I found it was much slower than Vue and the docs left a lot to be desired.

Re: Vue.js vs. React

#150

Earlier quoted context omitted.

JSX is closer to JS than HTML, which means it annoying to write in some cases. Quick, what does this render as? Link 1 | Link 2 | Link 3 It's not Link 1 | Link 2 | Link 3 as you'd expect - instead, the whitespace after the pipe character is eaten by JSX. This is because HTML is whitespace sensitive, but JS is not, and so to allow indentation, JSX trims whitespace. Here's another - { Object.entries(definitions).map(([…

It's funny you bash JSX, which is a very thin XML-like DSL on top of JS, and then turn around and claim that Vue's DSL is HTML Button Something tells me JSX is the better DSL.

When you make it so that (which is how everyone is writing Vue anyway)

   Button
   
   
   
It gets really, really clear that anything not in {{ }}, or attribute not prefixed by @ or : is HTML.
Post reply on HN