Some people say that you have the right to post such a high talk. In fact, this is the case. When I watched the live broadcast of the LOL game, a very famous broadcaster said, more than 2400 of the players are playing professional games, and 1800-2000 are still struggling. Only of the players are playing the anchor. However, if you are a competent programmer, if you can use any new technology or framework, you may be able to mask some real problems, but some may say the problem is a feature.
Many front-end developers are proud to despise jquery and use JQ-free as their capital. This is okay, because if your goal is ie9 + or mobile, the mvvm framework allows you to skip JQ. However, let's take a look at why we force users to upgrade IE8 to chrome? Win7 is such an excellent operating system. Internet cafe computers and even many office computers are xp. A large number of websites are compatible with IE8. the user is God. Are we qualified to ask God to upgrade the browser for no reason? Many programmers despise 360, but you should really thank 360,360 for using a gentle method to upgrade a large number of users to a browser with the chrome kernel. In contrast, YY is simply a rape of users, do something you want to do in the background.
Next, let's talk about where JQ is better. JQ is not a framework that is better than a framework. I hope every product manager can learn about JQ. The use of JQ is definitely not accidental, first of all, JQ's API design is very good (it is awesome to replace all selectors with $. Of course, the underscore underline should also be mentioned here ), I didn't know how to go there, but I also used Axios. Axios used Params and data in get and post, is this semantic or standard? I don't want to care about semantics, because the encapsulation of tool classes is to eliminate semantic differences and inconveniences and to be people-oriented. Many people criticize JQ for doing too much with a selector, but if JQ replaces $ with jqdom, jqstring, and jqselector, then how many people will use a framework.
The compatibility is not mentioned. JQ2 is perfectly compatible with JQ1, but some browsers are discarded. It is worth learning from the product manager that JQ focuses on solving Dom Operation Problems Encountered by programmers. By the way, it provides almost perfect Ajax encapsulation and some tool classes, there are almost no additional features. Therefore, before the mobile end becomes ineffective, many frontend JQ + templates handle everything. So I want to criticize JQ for making a big news?
Next, let's talk about the react. I have also recently jumped into this trap. There is no way. NG2 and vue are doing too poorly on a third-party Core Component I need, even the demo of this vue component cannot be opened, and star is also crushed dozens of times. However, this does not mean that react is no problem. Many people say that react is normal on jsx. Yes, I have been writing it recently, but jsx is flexible, the writing of nested functions makes you almost omnipotent. However, I would like to ask you in turn that the templates you have used in your life do not support if and for, regardless of JS, Java, and Python templates, at this time, someone jumped out to educate me that jsx is not a template. The template definition is too simple. A string supports replacement of variables such as $ {}. This is the template, and jsx fully meets this condition. Of course, the demands of the masses are always met, and NPM has a large number of if and for implementations that can be used.
Another point I want to talk about is Redux or flux. This design, in order to make up for the shortcomings of react's one-way data transmission (you can't say it's feature ), I think one-way binding is actually a kind of reversing, because both ng1 and NG2 are supported by dual binding, but react is one-way binding. At first glance, I saw Redux. Isn't this a state machine? Think about it again. I think back to this science's compilation principles, formal language, and automatic machine courses. Yes, the state machine is not simple, in particular, it is not easy to sort out the status of a large system and have high requirements on the team. Therefore, when selecting a project, we decisively rejected Redux's use of the previously familiar event model.
Here, by the way, there is a problem I encountered. A tab component requires very simple (1) to implement the basic tab function, that is, click the tab to highlight the tab and switch the corresponding tab (2) the Style and HTML of a tag are input by the user. You can only highlight the BG-color of the tag. (3) tab labels and content do not necessarily have adjacent or nested relationships on the Dom. This is optional. This requirement should be written using JQ or even the source, how much code does reactive development require?
Next we will talk about hybrid development. This is obviously designed specifically for enterprise development. Of course, we will not talk about how long it will take for a startup to collapse or get the money to turn into Native. Enterprise development and implementation are all right. Don't look for cool interfaces and smoothness. The intranet is not sensitive to network speed. No one in the internal applications can read your code or find your vulnerabilities, this perfectly avoids the weakness of hybrid development. No way. js features, No matter what obfuscation is, are bare and don't wear underpants. This is definitely not comparable to Lua, a scripting language that can be used in addition to traditional obfuscation but also magic parser. Now, in addition to the traditional H5 problems, your portal and users are all in the hands of others. Are you willing to do this? Maybe, in this way, we can purify the current app chaos and leave behind the functions really needed by users, that is, the "public welfare" applications of large companies and large enterprises, such as checking express delivery, registration, and checking the inventory list, these unattended and useless things are the perfect things for using small applications.
Recently, Rn and Alibaba's weex came out. This is the same as Cordova (some time ago, we were engaged in Cordova project upgrade. It was really the same as the name, And we wrote Cordova to read and do more digging) the system framework is different. No matter what the upper layer of Cordova, there are a large number of native plug-ins at the bottom layer that can adapt to the source function. Fortunately, there are too many react ships with RN, some people solve the native layer problem, but for the new Native framework, are you sure you want to fix it yourself.
The front-end users like to build wheels. A framework of URL Param splicing was found a few days ago. After installing the framework, other applications actually depend on two URL Param. The length is different. There are also a lot of isemail and isurl dependencies. Several projects have more than 600 node modules (including Dev dependencies, of course) at the beginning ), it would be incredible to put it in Java, because Apache utils provides an unknown set of functions. Now that Apache is mentioned, I want to talk about Java. Many people say that the frontend is changing, and the backend is the same as the dead water. I want to ask whether Taobao or 12306 in the past few years, all are results of frontend optimization. If the backend is put off, it can solve the high concurrency problem?
If a Java project is selected, spring will pass the entire vote as the underlying layer. Next, it may be the confrontation between mybatis and hibernate. This is almost the only choice based on the characteristics of the project, there is nothing to argue about. However, for front-end selection, I estimate that react, Vue, and NG will be available for one day. Therefore, the ten-year-old style of Java precipitated the essence of unknown. In addition to the optimization of virtual machines, there are also a large number of sports cars, which is not the wheel, including how many generations of Lucene have evolved (now elasticsearch is used), a series of data mining frameworks such as hadoop and spark, and other workflows and data bus are all embarrassed to say. But now the front-end jumps out, and they need to use js to sweep everything. I would like to ask if so many Java, PHP, Python, C ++, Erlang, and golang engineers are waiting to sit down?
It is a good thing to remain unchanged. js started in the beginning and now rapidly evolved to ecma2015, but the underlying running of ecma3 is still ugly (I do not reject God's requirements, god gave me money to make IE8 compatible), in contrast to how many people are using java1.6, python2.7, I believe that language and syntactic sugar are definitely not the first choice, because if you really like syntactic sugar, then you should support C #. The only explanation is that JavaScript developers are free of charge. Habits are a good thing. If stability and requirements are met, the TV you watch will be square for years, and the bicycle will be round-shaped for years. What is the JS world like now, there is a really awesome bicycle that is cool and fast. The only problem is that you need to implement your grip without a grip ..
There are two things between the rigid demand and the Self-chaos revolution. What is the real solution? One is JQ, and the other is the ng1 of mvvm on a large scale. Unfortunately, these two are all despised by you, then Google opened the NG2 car and found that a super-powerful complier built in the front end had increased the burden on the system, and AOT was not available until it was officially released a few days ago. Then, the HTML is mixed into JS like react. On the other hand, we can see that the architecture tools, glup and grunt, are already in history. When webpack emerged last year, some people wanted to break his life. What packaging tools will it be next year? Grunt has no error. Its design is batch processing, which can be achieved through compression, obfuscation, and integration. webpack is also a bundle for more convenient heating and debugging, so what feature does the new architecture tool allow users to discard their previous things and recreate a huge volume of wheels?
When will this mess be able? I don't know.
What is the experience of frontend development in 2016? Chaos + reversing, this is my experience