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

cordova-ravey

v1.2.0

Published

Cordova extension to add Rave Pay Button into your hybrid app builds

Downloads

6

Readme

Cordova Rave

A Cordova extension to add Rave Pay Button into your hybrid apps builds.

This module helps you easily integrate Rave into your Cordova builds. Rave lets you receive payments locally and internationally with no hassles and zero set up fees. Read more about Rave here.

e.g

Installation

In your app directory:

npm install cordova-rave

Setup

Two steps:

First, cd node_modules/cordova-rave && npm start

NB: If you get a warning of outdated npm dependency/DOS issue, please read this

This step will prompt you for a few config values which you should get from your Rave dashboard; except the last prompt (liveMode). The liveMode value either y or n used to change the Rave script used in your build from test url to live url. If you've signed up here https://ravepay.co, enter y for this option.

Completing this step creates a config file in the directory. You can modify this file later if you need to.

Second, npm run build This ultimately creates a rave.js file into your www directory. Link to this file in your root index template. If you modify your config.json at anytime, you need to run the build again.

Usage

Completing the setup above exposes a initRavePay function for you to call to tigger the payment modal.

Basic Usage: initRavePay(options)

  • options.customer_email - (Required if customer_phone is not passed) Email of the customer
  • txref - Transaction Reference (Required) (Unique per transaction)
  • options.amount (if not passed, the Rave modal shows amount input)
  • options.onclose (function) - Set behaviour onclose of the modal
  • options.callback (function) - Set how you want to respond after payment is done

The fields you pass here gets merged (with preference) on your app-wide setup done above. This final config is then passed Rave. See below more Rave options.


PBFPubKey - (Required) Public key of the merchant
amount - (Required) Amount to charge
currency - (Optional, defaults to NGN) Currency to charge the card in
country - (Optional, defaults to NG)
customer_email - (Required if customer_phone is not passed) Email of the customer
customer_firstname - (Required if customer_email is not passed) Phone number of the customer
customer_lastname -(Optional) Full name of the customer
pay_button_text - (Optional) Text to be displayed on the pay button
custom_title - (Optional) Text to be displayed as the title of the payment modal
custom_description - (Optional) Text to be displayed as a short modal description
redirect_url - (Optional) URL to redirect to when transaction is completed
custom_logo - (Optional) Link to the Logo image
meta-[custom_param] - (Optional) Any other custom data you wish to pass (Without the square braces)

Support :

  • For any bugs about this module, please feel free to report here.
  • And you are welcome to fork and submit pull requests.

License :

The code is available under MIT license.