My JavaScript exploration should be completed ~
Javascript is a clever board. Although the patterns that can be spelled out are limited, you can still spell out amazing patterns to make full use of your imagination.
Over the years, I have used JavaScript for a variety of special effects and games. Without exception, I want to demonstrate that JS + CSS is a powerful combination that can create unexpected interesting things. But after all, JavaScript is still a script. Although it can achieve a variety of powerful and complex effects, it has to pay more for both development efficiency and running efficiency.
Today, many browsers occupy the world, and each browser has its own features. It seems a luxury to use JavaScript to develop and run everywhere. For example, Internet Explorer supports filters, But none of others. Other browsers support canvases, but Internet Explorer does not. However, ie9 is available again. So what if I use a filter instead of a canvas? Of course it is better to use it than not, but after using it, you must find another alternative method for unsupported browsers... Sometimes it is time-consuming to study various versions for a non-complex effect.
But as a pure fan of JavaScript, this crazy effort is worth it ~ But sometimes it is a waste to think about how to use clever ideas in content implementation, rather than content itself. For example, I used to write a post that uses CSS to make a circular magnifier. This effect can be simply done using flash, but JS + CSS is a great deal of effort. Not to mention the production process, let's talk about the effect. js uses more than 50% of the CPU, while Flash achieves almost less than 1%!
Similarly, Flash has already provided a wide range of graphic interfaces when you don't need HTML5 canvases. When considering which method JS uses to play the sound and which method to transmit data, Flash has built in these functions, and all kinds of browsers maintain consistent performance, no longer need to care about the compatibility of the browser.
In fact, this can be implemented more than 10 years ago using Java applet. However, not every computer is installed on the Java virtual machine, and the flash plug-in is now almost a part of the system. Many portal websites cannot be normally displayed without it. Since XMLHTTP is also a plug-in, it is also a part of pure JS, and it is always fun. In this case, flash that can run on almost all computers should be part of Js ~
Flash has a lot to do. For example, DOM interaction and page layout. However, in many cases, the RIA with purely JS development functions is not worth the candle. The only drawback of Using Flash is that you cannot right-click it and a flash menu will pop up. However, compared with its powerful functions and compatibility, this is nothing.
Of course, it is not necessary to completely abandon js to use flash. It is often unwise to use pure XX to implement something.In fact, some of the users accessing your website know the technology. How can they care about how you implement it? They are concerned about the running speed, compatibility, and error.Your elegant, concise, and pure XX code can only be viewed by a few industry visitors.
Therefore, the most ideal method is to use the powerful media functions of flash and its fast computing speed. In combination with the flexible interaction of the JS front-end, JS + flash can be realized, create a new Web Front-end situation!