Я создаю телевизионное приложение в React Native и пытаюсь вручную активировать фокус на TouchableHighlight. Мой код:
class Button extends Component {
constructor(props) {
super(props);
this.focus = this.focus.bind(this);
this.buttonRef = React.createRef();
}
focus() {
this.buttonRef.current.focus();
}
render() {
return (
<TouchableHighlight ref = {this.buttonRef} />
);
}
}
Всякий раз, когда вызывается метод focus, я получаю сообщение об ошибке: Illegal number of arguments for 'updateHotspot' command. Как мне это решить?
@khateeb тебе удалось это решить?



![Безумие обратных вызовов в javascript [JS]](https://i.imgur.com/WsjO6zJb.png)

