Adds doc object in the plain js front end
Adds commits, saves are now recorded as commits