WIP: adding grunt, qunit and tests. refactored Represent library.