let selection = new SelectionState({
anchorKey: 'abc', // key of block
anchorOffset: 5,
focusKey: 'abc',
focusOffset: 10, // key of block
hasFocus: true,
isBackward: false // isBackward = (focusOffset < anchorOffset)
});
let s = new SelectionState(selection);
editorState = EditorState.forceSelection(editorState, s);
// Make sure to set this new EditorState as the editorState of Draft.js component