link to Google Play Store
Curious about an Architecture to rule all mobile platforms! using React Native and Golang!
- UI Layer: React Native
- Logic Layer: Go mobile using goku lib
- Persistence Layer Realm DB
As of now only works for Android, have not tested on iOS
- any one happy to contribute and build for iOS, I'm happy to receive Pull Request! :)
Dependencies: react-native for android
- clone this repo
- $ cd react-goku
- $ npm install
- $ react-native run-android
Dependencies: gomobile
- clone goku package
- $ cd goku
- $ gomobile bind -target android -o bridge.aar -v ./bridge
- Import .aar file using Android Studio:
- steps
- thanks to Sajal Kayan!
- Notice bridge.go, that's the proxy function used in order to communicate between Java and Go in Android.
- Limited types are supported using gomobile
Using Go package:
- Create a class that extends ReactContextBaseJavaModule, and create a method using the ReactMethod annotation, you can use Bridge.java to call the Go proxy function check this
- Create a class that extends ReactPackage, check this
- Pass the class in the getPackage function inside your MainActivity class
- This allows you to expose that class using NativeModules
- Profit! use that function wherever you want!
- input from buttons, not OS keyboard
- deleting sudoku boards
- updating sudoku boards, need to introduce primaryKey
- refactor to idiomatic react code : sorry came from Java and Go
- Realm Results should "auto-update" the list? or is it only "auto-updated" if it is already in the list? so adding new models I have to manually update the list again?
- Learn some integration testing for React Native
- (∩`-´)⊃━☆゚.*・。゚ Animations! oooooooh!!!!