I haven't found the official way of doing this but the editor uses a contenteditable div which you can target with .toastui-editor-contents. The below works:
document.querySelector('.toastui-editor-contents').addEventListener('input', fn);
The answer here explains how to detect a 'change' event for contenteditable elements.