Add build flags, phantomjs, gulp, ngHal contexts, and embedded docs

Sorry, this stuff is so mushed together that pulling out each of the features as a pull is going to be quite the chore at this point.