Shake

Contents

Handles shake gesture

https://github.com/leecrossley/cordova-plugin-shake

Stuck on a Cordova issue?

Installation

Community Enterprise
ionic cordova plugin add cordova-plugin-shake npm install @ionic-native/shake
Ionic EE comes with fully supported and maintained plugins from the Ionic Team. Learn More   or   Contact Us
ionic activate-native-ee --key=YOURPRODUCTKEY ionic integrations add @ionic-native/shake

Supported Platforms

  • iOS

Usage

import { Shake } from '@ionic-native/shake/ngx';

constructor(private shake: Shake) { }

...

const watch = this.shake.startWatch(60).subscribe(() => {
  // do something
  });

watch.unsubscribe();