This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import { Keyboard, LayoutAnimation, Platform, View } from 'react-native'; | |
/** | |
* An es6 version of RN KeyboardAvoidingView, with support for iPhone X safe area | |
*/ | |
class KeyboardSyncView extends Component { | |
constructor() { | |
super(); | |
this.state = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// add fetch import here. | |
const baseUrl = `http://localhost:8888/api/`; | |
class ResponseError extends Error { | |
constructor(messages) { | |
super(); | |
this.messages = messages; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Barcode.swift | |
import UIKit; | |
import AVFoundation; | |
@objc(BarcodeScanner) | |
public class BarcodeScanner: UIView, AVCaptureMetadataOutputObjectsDelegate { | |
let session : AVCaptureSession = AVCaptureSession() | |
var previewLayer : AVCaptureVideoPreviewLayer! |