npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

blinkinput-cordova

v4.3.0

Published

A small and powerful scanning library

Downloads

221

Readme

BlinkInput SDK wrapper for Cordova

This repository contains example wrapper for BlinkInput native SDKs (iOS and Android). Not all features of native SDKs are available in Cordova wrapper. However, the wrapper is open source, so you can easily add features that you need. For 100% of features and maximum control, consider using native SDKs.

Cordova version

BlinkInput Cordova requires Cordova v7.0.0 or later and cordova-android plugin v8.0.0 or later.

Ionic version

Latest version has been tested using Ionic 3.19.0 version.

Adding blinkinput-cordova to your application

You can add blinkinput-cordova by cloning the repository and following instructions below or by running

cordova plugin add blinkinput-cordova

The shown instructions are for Cordova, the instructions for Ionic are practically the same, except for some slight command line argument differences.

In the repository you will find scripts to create sample applications.

Clone or Download repository

Downloading a repository just downloads the files from the most recent commit of the default branch but without all the dependencies which are in submodules. We recommend that you clone directory. With a clone option you will get a copy of the history and it’s functional git repository.

To clone repository:

  • Copy URL from the Clone or download button: https://github.com/BlinkInput/blinkinput-cordova.git
  • Open terminal on Mac/Linux or GitBash on Windows.
  • cd into directory where you want the cloned directory to be made.
  • Type git clone , than past URL
  • Press enter

How to get started

Cordova

Sample Cordova app is generated with a script

./initCordovaDemoApp.sh

To run iOS demo application open Xcode project BlinkInputDemo.xcodeproj

To run Android demo application type

cordova run android

Ionic

Sample Ionic app is generated with a script

./initIonicDemoApp.sh

When Ionic asks the following question Would you like to integrate your new app with Cordova to target native iOS and Android? answer with y.

To run iOS demo application open Xcode project BlinkInputDemo.xcodeproj

To run Android demo application type

ionic run android

Licensing

  • Generate a free demo license key to start using the SDK in your app (registration required)

  • Get information about pricing and licensing of BlinkInput

Installation

First generate a empty project if needed:

cordova create <path> <package> <name>

The shown instructions are for Cordova, the instructions for Ionic are practically the same, except for some slight command line argument differences.

Initialize the iOS framework:

cd BlinkInput
./initIOSFramework.sh
cd ..

Add the BlinkInput plugin to your project:

cd <path_to_your_project>
cordova plugin add <blinkInput_plugin_path> # or blinkinput-cordova if you don't have blinkinput-cordova locally

Ionic specific:

Copy the BlinkInput plugin's JavaScript files to your project:

cp  -f -r <blinkInput_plugin_path>/www/js ./www/

Android

Add Android platform support to the project:

cordova platform add android@8

iOS

If you want to add iOS as a platform for your application, you will need to install unzip and wget.

Add iOS plaform support to the project:

cordova platform add ios

Sample

Here's a complete example of how to create and build a project for Android and iOS using cordova:

# pull the plugin and sample application from Github
git clone https://github.com/BlinkInput/blinkinput-cordova.git

# create a empty application
cordova create testcordova

cd testcordova

# add the blinkInput plugin
cordova plugin add ../blinkinput-cordova/BlinkInput # or just 'blinkinput-cordova' if you don't have blinkinput-cordova locally

# add android support to the project
cordova platform add android@8

# build the project, the binary will appear in the bin/ folder
cordova build android

# add ios support to the project
cordova platform add ios

# build the project
cordova build ios

In cordova CLI instead of platform add just request a build for the platform using build android or build ios. You will have to do the manual steps described above to be able to do a successfull build.

You can also use provided initDemoApp.sh script that will generate a demo app that uses the plugin:

./initCordovaDemoApp.sh

To run the script, you'll need BASH environment on Windows (Linux and MacOS use BASH by default).

Usage

To use the plugin you call it in your Javascript code like the demo application.

Documentation for all features and JS API is available in blinkInputScanner.js JS API file.

Changing scanner settings

To change scanner settings you need to modify Cordova plugin classes for iOS and Android. Plugin classes are located in ./BlinkInput/src. All necessary settings documentation is located in those source files.

For platform specific implementation details refer to the BlinkInput-iOS and BlinkInput-android documentation.