Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

tcg.plugin.phonecalltrap

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tcg.plugin.phonecalltrap

A phone call trap

  • 0.1.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

Cordova PhoneCall Trap

Forked from https://github.com/renanoliveira/cordova-phone-call-trap, It is a Apache Cordova plugin to simplify handling phone call status and events in Android devices. The original dint have the capacity to receive the calling number and I was too lazy to ask for a PR so here we are. Enjoy

Install

$ cordova plugin add tcg.plugin.phonecalltrap

Quick Example

PhoneCallTrap.onCall(function(obj) {
    
    var callObj = JSON.parse(obj),
        state = callObj.state,
        callingNumber = callObj.incomingNumber;

    switch (state) {
        case "RINGING":
            console.log("Phone is ringing", callingNumber);
            break;
        case "OFFHOOK":
            console.log("Phone is off-hook");
            break;

        case "IDLE":
            console.log("Phone is idle");
            break;
    }
});

Supported platforms

  • Android 2.3.3 or higher

License

Cordova PhoneCall Trap is released under the MIT License.

Keywords

FAQs

Package last updated on 01 Feb 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc