Build zepto. js files on mobile terminals and build zepto. js on mobile terminals

Source: Internet
Author: User

Build zepto. js files on mobile terminals and build zepto. js on mobile terminals

Because the files downloaded on zepto's official website http://www.zeptojs.cn/javasdownloadonly contain a few samples, which cannot fully adapt to what we need, and we also need to add the corresponding modules as needed. So we need to build our own zepto. min. js. You can use nodejs to bulid.

1. Install node. js

Http://nodejs.org/

2. Download zepto source code from github

Https://github.com/madrobby/zepto

3. Open the nodejs command line and find the zepto extract directory.

4. Modify make in the zepto extract directory.

Modules = (env ['Les le'] | 'polyfill zepto detectevent ajax form fx touch ios3'). Add the required MODULES to split.

5. Enter the command

Npm install

Npm run-script dist

6. generate two files: dist/zepto. js dist/zepto. min. js.

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.