In-depth analysis of the future of the JavaScript function library

Source: Internet
Author: User
Tags mootools

Over the past few years, function libraries have contributed a lot to the sudden popularity of JavaScript. JavaScript developers solve this problem. In addition, developers can develop solutions for problems they are interested in and apply these solutions to the business field.

I have been thinking about the future of the JavaScript function library, and I want the engine to be separated from the API.

Convenience of Selector Engine

There is a lot of debate over the speed of the function library selection engine, but the premise is that you have to use it. So what I call the selector engine refers to the customization based on my application: You can constantly change the selector Engine Based on your project.

Example: 1. Build a completely desktop web application-I want to use the selector engine as full as possible; 2, build a site version for the iPhone-I only need querySelectorAll because it can be supported; 3. Build a lightweight version that can be connected to a mobile device, I will use ID to limit JavaScript to the target element to keep it compact.

The selector engine has more and more options, especially when you know how to customize your application. What I want to see is: 1. Can we write plug-ins that import new engines into the database (such as jQuery, Prototype, and Mootools); 2, in the future, will mainstream function library versions support the pluggable query engine ). In short, developers can select the selector engine based on the specific needs of the application.

API Selection

Once the API and Selector engine are separated, the selection of function libraries is just a matter of personal interests. In addition, this separation allows more companies to create personalized function libraries based on existing engines or APIs. For example, the BBC created Glow-their own JavaScript function library because jQuery does not support Safari 1.

Challenges

Can the plug-ins of mainstream function libraries allow us to access the new selector engine in the function library? This is a challenge. I'm not Prototype or Mootools, so I don't know if it works. But it makes sense, doesn't it?

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.