Posts

Showing posts with the label native

Open native camera from react native

I am new to react native and need your help. I am new to react native I am trying to integrate blink sdk with my react native app. I have exposed a native method to react native js using RCT_EXPORT_METHOD() . JS button click is invoking this native method. Now from this native method I want to open camera using: /* Allocate and present the scanning view controller */ UIViewController<PPScanningViewController>* scanningViewController = [coordinator cameraViewControllerWithDelegate:self]; scanningViewController.autorotate = YES; scanningViewController.supportedOrientations = UIInterfaceOrientationMaskAll; Now there are two problems: If I run it just like that, it gives me red screen saying "invoke the method on main thread". Now to run it on main thread, I added -(dispatch_queue_t)methodQueue { return dispatch_get_main_queue(); } Still it is not running and saying not present in view hierarchy. Please help.

Bluetooth Printing in React Native

Is it possible to connect to thermal receipt printer via Bluetooth in react native? If yes the how to connect receipt printer via Bluetooth in react native? Yes it's possible to connect a React Native app to Printer via Bluetooth. The package called react-native-ble-plx allows you to do so. Read their documentation at Github.io You can also try react-native-ble-manager : Full source code can be found here.

React Native Installation

I'm trying to install React Native by following instructions on this page : https://facebook.github.io/react-native/docs/getting-started.html but when I want to run my new project I obtain several errors and a log file is created with all what happened during the procedure. The link to see the log : https://drive.google.com/open?id=0B8Sis1RFrKgiZTFTRWFLUmZpZlk Thank you ! You need to install git, as you log says. 2223 error not found: git 2224 error Failed using git. 2224 error This is most likely not a problem with npm itself. 2224 error Please check if you have git installed and in your PATH. 2225 verbose exit [ 1, true ] Here you can find how to do it: Installing Git

React native for beaglebone

I want to develop mobile app to access beaglebone board. Can react native provide access to beaglebone board. Currently I have developed web app with javascript and Nodejs to interact with BeagleBone. Want to implement the same in Mobile app. Does React Native provide option to interface and recognize beaglebone board. For web I either access BeagleBone via USB or Ethernet

global state react native

I just developev some app with react native and in my code I'm just receive mobile phone in state .how to set this state in global and use in another screen like as OTP screen how to use this in another screen. I use react native router flux. Can I send this data in second variable in next screen? react native .049 phpstorm android studio export default class Login extends Component{ constructor(props) { super(props); this.state = {mobile: ''}; this._OtpButton = this._OtpButton.bind(this); } _OtpButton() { fetch("https://2d44f003.ngrok.io/mobileWebViews/v1/sendOtp/", { method: "POST", headers: { Accept: "application/json", "Content-Type": "application/json" }, body: JSON.stringify({ mobile:this.state.mobile, type:'otp' ...