官术网_书友最值得收藏!

  • Learning Grunt
  • Douglas Reynolds
  • 377字
  • 2021-07-09 20:22:48

Chapter 1. Grunt Dependencies

Grunt is a JavaScript task runner. As its name alludes, this tool performs the grunt work of completing development tasks, which might include linting JavaScript, running tests, generating minified JavaScript and CSS, moving files and directories, creating archives, and the list goes on and on. In fact, the purpose of Grunt is task automation, which means running one or more tasks with the least amount of user interaction needed in order to complete the work. Almost any task can be automated with Grunt and many plugins (tasks) already exist that can be installed and used in your project. It is possible to write and publish your own plugins to meet the need of tasks for which a plugin does not already exist. You can also modify existing plugins to meet project-specific requirements. The Grunt community is very large and there is a great deal of documentation and resources available as a result. With a minimum amount of research effort, information on specific Grunt topics can be found in a wide range of places. This book, for one, will provide information on the installation and setup of Grunt, installation and configuration of tasks found in the Node Package Manager (NPM) registry, creation of custom tasks, Grunt API documentation, and much more. Some main benefits of using the Grunt task runner are that Grunt task automation improves productivity by handling repetitive tasks with efficiency, reduces errors using automated processes, and lessens the workload so that less time and energy is spent on things that can be handled through workflow automation. Once the upfront work of Grunt implementation has been completed, there is practically no additional work needed to run tasks. It is a very simple matter to create custom task runners for various build stages of projects with fine-grained control over what tasks get run for various stages. For instance, it is possible to create a custom task that includes error checking and syntax validation, running a suite of unit tests, and then, upon success, building the project to a development release version and generating a deployment archive. The possibilities for various build configurations are vast. However, first things first, there are some things that need to be discussed prior to ping in.

主站蜘蛛池模板: 兴义市| 弥勒县| 伊吾县| 宜黄县| 聂荣县| 古丈县| 屏南县| 伊春市| 五峰| 怀集县| 长岭县| 久治县| 湖南省| 无锡市| 会泽县| 政和县| 紫阳县| 乾安县| 铁岭市| 运城市| 阿坝县| 台前县| 石棉县| 汉中市| 汉阴县| 山丹县| 邯郸市| 堆龙德庆县| 靖西县| 泾源县| 新津县| 海口市| 安义县| 乌审旗| 广丰县| 扎鲁特旗| 潼关县| 济源市| 重庆市| 永嘉县| 台州市|