At Rever (www.reverscore.com), we just released a new version of our Web client using vue.js. After 641 submissions and 16 weeks of intense development, we are very proud of the decision we made earlier. Eight months ago, our front end was using Angular 2. Specifically, it was using Angular 2 Beta 9. This is a product written by an outsourcing company that we are not completely satisfied with on many levels, from UX/UI to architecture, and to some extent, Angular 2 itself.

Previously, I acknowledged that Angular 2 Beta 9 is a different product from Angular 2.0, but that’s one of the problems. From Beta9 to 2.0.0, there are 8 beta releases, 8 RC and 2.0.0 for a total of 17 releases that need to be upgraded. We did try to upgrade from Beta 9 to 2.0.0 but too many API changes made the upgrade very difficult. In addition, around the same time we questioned Angular 2 as our framework of choice, the Angular team decided to start working on Angular 4. Although they promised that the version change would not be too drastic, this meant that 2.0.0 would need another upgrade when we finished upgrading to Angular. What a waste of time and few resources.

The main reason we don’t like Angular 2 is that it’s developed in Typescript. I know Angular 2 works with Javascript, but again, the decision to use Typescript is already being used internally, and from what I understand, using pure Javascript and Angular 2 is not the ideal way you should use Angular 2. In any case, getting rid of Typescript means completely rewriting the project.

I don’t feel that Typescript adds real value, and worse, we’ve noticed that our coding speed has slowed down. The things that are easy to do in Javascript with Typescript are just as complex in Typescript as defining a simple object. I strongly encourage you to read the following articles before you start working with Typescript. This is not necessarily the right solution for everyone.

I remember how easy it was to use Angular 1. It had its limitations, but Angular 2 lost something along the way compared to other frameworks. The conclusion about Angular 2 is simple. The only thing that Angular 1 and 2 have in common is their names. They are completely different frameworks.

Therefore, considering we have 17 on untested system version upgrade, a lot of pressure from business to write new features, a large number of errors and bad code, the original developer is no longer in the team, there is only one developer (I) at that time, a lot of other responsibilities, since I use the beta right document, And Angular 2 moving to version 4. Bad news about him began to accumulate rapidly.

We made a decision that if we were going to spend that much time upgrading, we might as well look at other frameworks.

To deal with

The first obvious choice is React, because most companies use it and the useless people are talking about it. So it’s an option, and of course it’s helpful to know that Facebook supports it. However, React itself is not a simple framework, and you need to add additional components to make it shine.

Vue.js

Vue.js was a new player and I had never heard of it before, although we started thinking about different frameworks when they released version 2. It caught our attention at first, but there are risks.

The decision making process

We start by defining our decision points. We know that a framework needs the following:

  • It should be stable
  • Supported by a strong community or some big players
  • There is good documentation on StackOverflow or many problems solved
  • Easy to learn
  • With the integration of the Bootstrap
  • small
  • Ideally, it allows us to reuse code
  • Coding speed should be increased
  • Based on the component

After we listed all the requirement points, I had to get started, so I gave React and vue.js a couple of days to individually review each decision point that Google couldn’t answer. Since I knew nothing about any of them, at the end of two days I would reassess how much I had rewritten some parts of the actual project we were migrating.

The part I chose to rewrite was:

  • Some basic API calls
  • Two layouts for two different pages.
  • Compatibility of user-related content
  • Login forms and some content forms
  • A bootstrap pattern

I was amazed at the strength of Vue.js and within a few days I actually had a proof of concept to show to the rest of the team and my CTO. I got a good understanding of the basic concepts of vue.js and defined a good, extensible architecture, but most of all I really enjoyed the experience of writing code with it and found it quicker to get started than React.

React was a lot harder than I thought, and choosing between Redux and MobX was more problematic than having an option to fully integrate with frameworks like vue.js and Vuex. This is easy because it makes you more confident when there is no framework experience, rather than a framework having a formal library to do something with. BTW, I find Vuex easier to fit than Redux, but maybe it’s just a perception of the individual, like all learning curves.

JSX is also a problem because we can’t reuse HTML code, and vue.js does allow us to do so to some extent. Vue files are actually pretty good to use because I don’t like inline templates. React mixes JSX/HTML with JS code and I just don’t like it because I’m a big believer in separation of concerns and it looks ugly.

The encoding speed

Encoding speed is vue.js’s area of expertise and not having to learn JSX is a huge help. The project starts a few hours later when another developer joins the project and follows a training session of about an hour.

This is very important to us, and you can see it immediately by opening the Vue file. It contains a template section with HTML and tags that looks similar to Angular 1, so if you’ve done some Angular 1, it will be very familiar. A Vue file also has a style and pure javascript section, you actually use javascript, you just need to learn a few things about vue.js to fully understand them. Understanding vue.js properties (such as methods, calculations, properties, data, and creation) will give you an idea of about 90% of what you need to start coding, quite simply.

The document

To get the right speed, we need good documentation and vue.js documentation to be first class. The guides, examples, questions, and apis are well documented and cover all the questions we found during development. We were afraid to find Chinese documentation for many of the problems we would encounter, but that wasn’t the case; everything was provided in English.

Question and answer

After more than a week of thinking about it, vue.js performed very well, but to my surprise, the surrounding issues were resolved as no one had used vue.js before and the only comment I got was “it looks cool, but I haven’t” used it yet “. React gets the most mentions, with Angular 2 in second place.

I started looking for local talent with vue.js experience, and I did find some really good people, so I started thinking THAT I wasn’t alone, that my social tech circle might be too small and that I shouldn’t be on the fact that I didn’t know anyone working with vue.js.

The mobile terminal

While we were considering vue.js vs React, we were also considering rewriting our mobile app, and React Native seemed like a great choice. This is a big advantage for React, because Vue. Js doesn’t have anything like the long term stable development that React Native is trying to do, so the possibility of reusing code between the network and application clients is a huge advantage, but I decided I wouldn’t consider it. After all, in my experience, with Node.js, I reuse a very small amount of code between the browser and the server.

The license

There was a lot of discussion as I wrote this, because Facebook changed the React license to a BSD + patent. According to Facebook, the license is meant to protect them from patent trolls. It wasn’t the most original in our decision-making process, but I’m glad we didn’t go the React way, because any license-related noise isn’t the noise you want to hear.

Ultimately, Facebook falling behind React may become a liability rather than a strength of the project, which is why it’s often better to have independent foundations or organizations responsible for successful open source software projects. Facebook should do the right thing. Take IBM for example. When IBM acquired Strongloop, they donated Express.js to the foundation of Node.js, an important piece of software. Community pressure and IBM’s willingness ensured software continuity. Twitter is another great example, they released Bootstrap under a very loose MIT License, and no one is talking about the License for Bootstrap.

The last word

Among the many web pages I studied before making my decision, one chart that caught my eye was developer satisfaction with the status of the Javascript survey Sacha Greif @sachagreif conducted annually. I admit, as the authors did, that this was not a scientific survey, but it did provide a lot of information that was later confirmed by our decision points when we had a clearer picture, especially with respect to vue.js, because we knew nothing about it at the beginning of our research. You can read the Javascript status through the following link.

Overall, vue.js was the winner in our evaluation, it had a lot of problems on Stack Overflow, official documentation for the simplest three options, minimal code base, and good integration with Bootstrap, And learning that it is Laravel and big companies like Alibaba that have strong project support is a big advantage. Not having a community as big as React wasn’t really a factor in my decision to use it, because it was big enough on its own.

Choosing Vue.js was the right choice and it took me a while to convince my CTO that I am very grateful to him for always asking the right and tough questions and being 100% positive about my decisions. If I’m wrong, I’ll regret it.

The whole decision-making process really helped in the end, but the fact that I was able to learn quickly made a huge difference, call it intuition if you like, but learning something really fast gave me a lot of confidence in more complex problems. I knew I would face it during actual development.

I’m not saying React is a bad choice, I was surprised by how large the community was, and for good reason, while jQuery is also used by a lot of people and doesn’t make it a good framework/library for the project we wanted to do.

Vue.js is gaining support from more developers, and we’re seeing that in development, which gives us more confidence that we’re making the right choice.