fixes lots of syntax bugs, updates grunt to build and adds some html-based syntax checks in tests