I see. According to the documentation "`text` is an array of strings representing the text that replaced the changed range (split by line)." There's a bit of trickiness here. If you press `Enter`, then you get `['','']`, without taking automatic indentation into account. On the other hand, if you paste something like `  abc\n  def`, you get `['  abc', '  def']`, which does have automatic indentation. I'm not sure how to work around this. @marijnh do you have thoughts?

I'm going to guess that if `Enter` is always an individual change event. While we probably shouldn't rely on it, I don't see a way around it. If you get an `['','']`, assume it's an `Enter` and record `<Enter>`. If it's anything else, assume it's a paste and record `\n` for the breaks. And then during replay, if `Enter` is encountered, trigger an `Enter`. If `\n` is encountered, simply insert it as a character.

Finally, it doesn't look like you are processing the `next` property on `change` objects. According to the documentation: "If multiple changes happened during a single operation, the object will have a `next` property pointing to another change object (which may point to another, etc)". I've managed to make it show up by pressing a key and then enter together very quickly.