Taswar Bhatti
The synonyms of software simplicity
Category: javascript
Grunt

Sorry for not blogging for a while, have been busy with joining a new company. I wanted to finish up the blog post series with Running Grunt to test your JavaScript application. In this post I will cover using Jasmine and Phantom.js. I have been a big fan of phantomjs a headless browser to test […]

Grunt

Using Grunt JavaScript Minification We will continue from our last blog post on Grunt: using less and css minification to JavaScript minification using a plugin called Uglify. JSHint To begin we will use a linting tool called jshint, to help us in taming our JavaScript with some static code analysis to flags suspicious usage. We […]

Grunt

In this post I will go through using grunt for our css minification task and also showcase another preprocessor for css called less. First off lets start with a express 4 application, we will create it with Visual Studio NTVS, the latest RC contains a template for express 4. We can install grunt by command […]

Grunt

Sorry for not posting regularly here, I was on holidays during late December till January, so didn’t get the time or the change to blog, but will get back to the routine of blogging more often. This blog post will be the continuation on Using Grunt. We went through some basic of using Grunt, in […]

Grunt

Visual Studio 2013 provides Task Runner Explorer for us to run Grunt & Gulp task right inside of Visual Studio. One can download Task Runner Explorer from Visual Studio Gallery Once installed we can now use npm to install grunt for us in our node web project.

We now will create a new Gruntfile.js […]

Grunt

In this post I will show how to use Grunt Launcher in Visual Studio 2012, there is also Task Runner but it only works in Visual Studio 2013, and there are no plans to making it to work in 2012. 🙁 No worries since there is Visual Studio Grunt Launcher that one can use in […]

Grunt

So what is Grunt? Grunt is a task-based command line build tool for JavaScript projects. If you are in the .NET world you may have written some bat files to automate some task, e.g copy some files from one directory to the other. Or have used Psake or MSBuild

And if you come from […]

conversion

In this post I will write about some tips on JavaScript Conversion from type to values etc. Tip 1: Boolean values In JavaScript one can use the double not (!!) to convert a variable to a Boolean. What the !! operator (poor man casting) does is, it first cast the data to a true Boolean […]

javascript

Here is another quick tip on JavaScript, the default value in Javascript. If you are coming from the C# world you may have seen something along the line of

The above code shows the ?? for null coalescing operator in C#, don’t confused it by the generic default value. In JavaScript, there is the […]

Javascript

In JavaScript there are two types of equality operator, the === and the !== , sorry I forgot to mention their evil twin == and != . tsdr; (too short didn’t read) Use three equals unless you fully understand the conversions that take place for two-equals. Basically what the triple equal (===) compares is if […]

UA-4524639-2