Grunt--JavaScript automation tools

Source: Internet
Author: User

Grunt is a tool framework based on Npm,node.js with JS, which can automate some repetitive tasks (such as merging files, grammar checking, compressing code),

Grunt has a large library of plug-ins to meet a variety of automated batch processing needs, commonly used plug-ins are:

Concat---> Merge files
Csslint---> CSS grammar checker
Cssmin---> CSS compression
Jshint---> JS grammar checker
Uglify---> JS compression
Watch---> Automation core, monitor file modifications and execute plugins

Plug-in Installation instructions:

NPM Install grunt-contrib-concat--save-devnpm install grunt-contrib-csslint--save-devnpm Install Grunt-contrib-cssmin--save-devnpm Install grunt-contrib-jshint--save-devnpm Install grunt-contrib-uglify-- SAVE-DEVNPM Install Grunt-contrib-watch--save-dev

NPM Package.json Configuration after installing the plugin

1 {2"Name": "Grunt_test",3"Version": "1.0.1",4"Devdependencies": {5"Grunt": "^1.0.1",6"Grunt-contrib-concat": "^1.0.1",7"Grunt-contrib-csslint": "^2.0.0",8"Grunt-contrib-cssmin": "^1.0.2",9"Grunt-contrib-jshint": "^1.0.0",
One"Grunt-contrib-uglify": "^2.0.0", A"Grunt-contrib-watch": "^1.0.0" - } -}

[The weight of the heaviest] Gruntfile.js Grunt configuration file

Grunt--JavaScript automation tools

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.