For a hackable, open source collaborative framework, check out Mozilla's TogetherJS: https://togetherjs.com/
Except that it only supports viewing one persons view and doesn't support changes in content on both sides.
And certainly not any recording.
Hahah, I experimented with a collaborative WebRTC feature for our code editor this summer. It ultimately never made it off its feature branch. Fun to see someone else implement it!
Awesome job, reminds me a lot of Mozilla's towtruck