react-native-china / react-native-qrcode-kit

📦 Generating,Scanning,Decoding qrcode.For awesome react-native
MIT License
12 stars 2 forks source link

Syntax error when import QRCodeScanner #4

Open aisgirish opened 7 years ago

aisgirish commented 7 years ago

Hello, I am trying use your code to qrcode scanner. But I got error when I assign into var. Please see my code.

var QRCode = require('react-native-qrcode-kit/QRCodeScanner');

var QRCode = require('react-native-qrcode-kit/QRCodeScanner');

export default class QRScannDemo extends Component {
  render() {
    return (
      <QRCode/>
      );
  }
}

But I got error into simulator as well as Device.

SyntaxError /.../react-native-qrcode-kit/QRCodeScanner.js: Unexpected token (3:12)

Obooman commented 7 years ago

It seems that the package import method is invalid now.I'll take my time repair it and I'll let you know once I publish the new version,thanks for your response.