Extract document methods that don't modify it
Create a text change event
Create an interface to intercept and modifiy text change events
Add text change interceptors to editor configuration
Initialize text change interception