Update to code mirror 4.1.0 and redesign the API

Code mirror now uses `require` to specify dependencies, so there's no
need to load dependencies manually.  This is a huge boost to the
usability of the module.