Skip to content

Easily implement barcode/QR scan with few lines. No boilerplate code, no xib, no storboards.

License

Notifications You must be signed in to change notification settings

harshalrj25/BarcodeEasyScan

Repository files navigation

BarcodeEasyScan 📢

CI Status Version License Platform

Easily implement barcode scan with few lines. No boilerplate code, no xib, no storboards.

Example 📚

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation ⏳

BarcodeEasyScan is available through CocoaPods and Carthage:

To Install for CocoaPods

pod 'BarcodeEasyScan'

Or Install for Carthage

github "harshalrj25/BarcodeEasyScan" "master"

alt text

Usage 💡

Import the pod inside your viewcontroller class.

import BarcodeEasyScan

You need to add the "Privacy - Camera usage description" key to your app’s Info.plist

Present 'BarcodeScannerViewController' and assign its delegate to self.

// Call this controller to open barcode screen
let barcodeViewController =  BarcodeScannerViewController()
barcodeViewController.delegate = self
self.present(barcodeViewController, animated: true, completion: {
})

Use the 'ScanBarcodeDelegate' to implement userDidScanWith(barcode: String) method.

func userDidScanWith(barcode: String) {
// This method results the scanned barcode string
}

Author 😇

My email id, harshalrj25@gmail.com

Harshal Jadhav

License

It's all your's 🎁