Posts

Showing posts from September, 2015

UI Build and Deployment

using grunt to automate build and deployment What is Grunt? There are many references available online to describe this question but to keep it very simple, Grunt is a Javascript task runner which allows us to automate task such as compilation, minification, unit testing, linting etc.
Iteration 1 - A Sample Application: To start with, we will be referring to a very simple UI application which shows an alert on page load. It can be downloaded from here. It contains three folders
csshtml andjavascript On this application we will be adding below tasks for Grunt automation
JS Lint,JS Minification,CSS Minification andHTML Compression Iteration 2 - GruntFile.js: To begin with any Grunt based setup we need to create a file "Gruntfile.js". Its a simple JavaScript file which define various tasks which can be executed during our build phase.
// a sample Grunt File module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), uglify: …