bamlab / bamlab/react-tv-space-navigation
React native 0.78 compatibility
- Dominant language
- TypeScript
- Stars
- 319
- Forks
- 46
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the bug**
Hi,
I'm in the process of migrating to React Native 0.78.0 and React 19, and there appear to be compatibility issues with the library in version 5.1.1.
**To Reproduce**
```tsx
import {Directions, SpatialNavigation} from 'react-tv-space-navigation';
import {LoggerService} from './logger.service.ts';
import {remoteControlService} from './remote-control.service.ts';
import {SupportedKeysEnum} from '../model/enums/supported-keys.enum.ts';
export class SpatialNavigationService {
private constructor() {
}
public static init(): void {
SpatialNavigation.configureRemoteControl({
remoteControlSubscriber: (callback) => {
const mapping: { [key in SupportedKeysEnum]: Directions | null } = {
[SupportedKeysEnum.Right]: Directions.RIGHT,
[SupportedKeysEnum.Left]: Directions.LEFT,
[SupportedKeysEnum.Up]: Directions.UP,
[SupportedKeysEnum.Down]: Directions.DOWN,
[SupportedKeysEnum.Enter]: Directions.ENTER,
[SupportedKeysEnum.Back]: null
};
const remoteControlListener = (keyEvent: SupportedKeysEnum): void => callback(mapping[keyEvent]);
return remoteControlService.addKeydownListener(remoteControlListener);
},
remoteControlUnsubscriber: (remoteControlListener): void => {
remoteControlService.removeKeydownListener(remoteControlListener);
},
});
LoggerService.info(`[SpatialNavigationService] Initialized spatial navigation service on TV`);
}
}
```
```tsx
```
**Expected behavior**
Application continues to work as it normally did in previous versions of React native (in my case 0.76.5).
**Screenshots**



**Version and OS**
- Library version: 5.1.1
- React Native version: 0.78.0
- OS: Android
**Additional context**
Add any other context about the problem here.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the reported setup on Android with react-tv-space-navigation 5.1.1, React Native 0.78.0, and React 19 using the shown SpatialNavigation configuration and component tree. Compare it with React Native 0.76.5 and inspect the compatibility failure shown in the attached screenshots; done means the application works as before on the newer versions.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react-native, typescript
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100