Taswar Bhatti
The synonyms of software simplicity
Tag: Javascript
Jade

Jade Node.js Template Engine, Filters & Mixins In my previous post I have talked about conditional statements inside of jade. In this post I will write about filters and mixins in jade template engine. Filters Filters in jade means something different from what you may know as filters like the ones in Angular.js. In Jade […]

Jade

Jade Node.js Template Engine, Conditional Logic Statements In my previous post I have talked about databinding with jade, i.e. feeding data to your template. In this post I will write about how one can use conditional and logical statements (for, if, while statements) in jade template engine. Ternary Operation The conditional ternary operator can be […]

bower

Continuing on our previous blog post on bower, in this blog post, I will talk about how to create your own front-end packages in bower. One thing I forgot to mention in the previous post is git is required when using bower. If you are using windows you can install git for windows or Mac/Unix/Linux. […]

bower

My last blog post was about using bower in node.js express application Visual Studio, and I believe I did not do justice to it. In this blog post I will talk more about how to use bower for your front-end and all the command line associate with bower. Again to install bower globally one can […]

node.js

In my previous post I have shown how to create an express app with node.js and in this post, I would like to introduce bower a package manager for front-end development. Bower is a package manager just like Nuget, where it gets confusing is that node already has a package manager called npm. The difference […]

jquery

I recently had to do work on localeCompare in JavaScript and though I would write a plugin in JQuery and share it. Javascript Locale Compare JavaScript provides a localeCompare function for comparing two strings in the current locale. The locale is based on the language settings of the browser. To explain locale compare lets look […]

node.js

Here is a quick little tutorial of using Twitter Bootstrap with Node.js express in Visual Studio. First we will create a ExpressBootstrap solution, select New Project and select JavaScript -> Blank Express Application. I will name my solution ExpressBootstrap, in my app.js I have also add the app.locals.appname = ‘Express Bootstrap’ so that I can […]

node.js

Node Tools for Visual Studio is currently in Alpha 1.0 and its free and opensource, in this post I will show you how to install Node and Node Tools for Visual Studio (NTVS). First lets install Node.js Download Node from http://nodejs.org/ The currently version is node-v0.10.26-x64 Step one lets run the msi that we just […]

phantomjs

Thanks to everyone who came out last night at OttawaJS for the phantomjs talk, the slides are located at slid.es. You can find the code in my github account. https://github.com/taswar/ottawajs-dec2013 A recap of things we covered: Simple screencapture CoffeeScript with phantomjs Scraping hackernews and dzone site for links using webdriver to integrate with phantomjs (python […]

jquery

Was debugging some code that was broken due to jquery 1.6 update, and found this call for Jquery dropdown.val

Not working anymore but a simple fix of changing it to

This does the trick, for more on prop take a look at the api of jquery http://api.jquery.com/prop/

UA-4524639-2