draft-js
draft-js copied to clipboard
Confusion on usage of onTab vs. keyBindingFn
Do you want to request a feature or report a bug? More of a question about best practices. 'tab' inputs can be handled by onTab, but it seems like it is preferred to use keyBindingFn.
What is the current behavior? When a 'tab' character is input, only 'onTab' is invoked from editOnKeyDown.
This causes me some confusion since 'onTab' is marked as deprecated and emits a warning in the console when you use it in DEV.
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem. You can use this jsfiddle to get started: https://jsfiddle.net/stopachka/m6z0xn4r/.
What is the expected behavior? I would expect both 'onTab' and keyBindingFn to be invoked while 'onTab' is supported but marked as deprecated.
Which versions of Draft.js, and which browser / OS are affected by this issue? Did this work in previous versions of Draft.js? 0.10.5 Testing on Chrome for Mac
This is related to #792 and #1280.
This is fixed on v0.11.0-beta2