Rewrite the history module
Rewrite the history module

 - Compression is now synchronous (and thus simpler, less error-prone)

 - State is kept in a single array, rather than two arrays

 - The concept of a 'version' is done away with

 - The code now makes more effective use of the separation between
   applying a step and getting a position map (making compression much
   cheaper)

 - Various bugs and awkwardnesses fixed

Issue #266

ProseMirror/prosemirror-collab