'Custom keyboard for react native

I am trying to implement a custom keyboard with react native. Can anyone provide me with any good packages or guide me in the right direction.



Solution 1:[1]

That's not going to work. There's several problems with this.

1)You need to have an InputMethodService. That means at best you could write a native app that has a ReactNative view.

2)Several of the IMS functions need to return a synchronous value. ReatNative works by running Javascript asynchronously on its own thread. There is no way to make this work.

3)Unless all your logic is in the native code, you'd need to be able to call react native when calls are made to the IMS. But that isn't possible in React Native as of last time I looked- RN can call out to native code, but there's no way to pass a function call through to react native.

The absolute best you could do is an RN view and all the logic in native code. Which would be painful and harder to do than pure native.

Then on top of all this- performance raises its head. Keyboard apps need to launch and display quickly, and preferably use as little memory and CPU as possible. Launch times and resource usage of RN apps are very high. It's a bad fit even if it was possible.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Gabe Sechan