react-native-rongta
v0.2.8
Published
TODO
Downloads
60
Readme
react-native-rongta
Getting started
$ npm install react-native-rongta --save
Mostly automatic installation
$ react-native link react-native-rongta
Usage
import RNRongta from "react-native-rongta";
// TODO: What to do with the module?
// get list device
RNRongta.getDevicesList((error, listDevice) => {
}
// connect device
NativeModules.RNRongta.connectToDevice(item.id, isSuccess => {
if (isSuccess == '1') {
alert('Connect success');
this.setState({isConnect: true});
} else {
alert('connect failed');
this.setState({isConnect: false});
}
});
// print
RNRongta.print('test print');