Added the ability to use source maps (grunt dev)

And other small fixes.