Refactored code, added grunt with jshint.
Merge pull request #1 from rcorral/master

Refactored code, added grunt with jshint.