Use indexOf instead of includes in RangeKeyboardFixture (#11133)

Allows the DOM Fixture change test case to work in older browsers.
This commit is contained in:
Nathan Hunzaker
2017-10-06 10:45:57 -04:00
committed by GitHub
parent 7ec46e0fb0
commit ea507f163b
@@ -30,7 +30,9 @@ class RangeKeyboardFixture extends React.Component {
handleKeydown = e => {
// only interesting in arrow key events
if (![37, 38, 39, 40].includes(e.keyCode)) return;
if ([37, 38, 39, 40].indexOf(e.keyCode) < 0) {
return;
}
this.setState(({keydownCount}) => {
return {