Comment

Comment by roblabla

I recently tried out vue.js on a projet as a replacement to d3's selection/data-binding magic. I have to say, I've been impressed.

1. The API surface is fairly small, especially compared to Angular. I could grok how it worked very fast.

2. The fact that it works without build tools is a godsend. My project is fairly small, and having as fast an iteration cycle is really nice.

3. The debug tools are awesome. EDIT: https://github.com/vuejs/vue-devtools

However, I do have a BIG problem: the fact that mutating the data automatically does a rerender is a nice idea, but in practice it falls apart very quickly and leads to fairly hard-to-debug bugs. For instance, if I add a new field to an object, it will not be detected as a change by Vue and not cause a rerender[0]. In my case, it broke the magic and caused me to look into how the heck did vue actually work - only to find out I had to call this.$forceUpdate() in a few places. It's terrible.

React, despite its problems, is nice because of exactly this : its data binding is entirely non-magical. You have to go through setState or force an update. The mental model is dead simple. I wish I could like vue more...

[0] It is somewhat documented here: https://vuejs.org/v2/guide/instance.html#Data-and-Methods among other places

parent roblabla 9 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton