How to setup multi line editors in javascript grid

Multi line editors can be set up in many different ways. Here are the 3 common ones:

Feature 1st col 2nd col 3rd col
type contenteditable contenteditable textarea
New line Enter key Alt + Enter key Enter key
Resize Automatically with content Automatically with content Manually by dragging the edge of editor
Effect of scroll scroll with grid scroll with grid fixed
overflow remains within grid remains within grid overflows outside grid