ProseMirror is probably the best option out there, but I found it pretty hard to wrap my head around its API.
The docs are detailed and exhaustive but did not help me much understand how to actually use it. I had to read Marijns code which I found hard to follow.
I started this introduction to PM (which is incomplete since I stopped using it) but I think will help anyone trying to use it.