Socket
Socket
Sign inDemoInstall

ionic-swipe-all

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ionic-swipe-all

Allow Ionic (≥ v2) to recognize both horizontal and vertical swipe gesture.


Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

Ionic Swipe All

Ionic Swipe All allow Ionic (≥ v2) to recognize both horizontal and vertical swipe gesture.

Installation

npm install --save ionic-swipe-all

For Ionic 2 RC.0 and later:

import { IonicSwipeAllModule } from 'ionic-swipe-all';

@NgModule({
  imports: [
    IonicSwipeAllModule,
  ],
})
export class AppModule {
}

Usage

With this module you can use (swipeup) and (swipedown) events. In the (swipe) event vertical gestures are detected. Just add the swipeAll property to the element you want to swipe and use the events as needed. The (swipeleft) and (swiperight) events are available too.

@Component({
    template: `
      <div swipeAll
           (swipe)="swipeAll($event)"
           (swipeleft)="swipeLeft($event)"
           (swiperight)="swipeRight($event)"
           (swipeup)="swipeUp($event)"
           (swipedown)="swipeDown($event)"
      ></div>
    `,
})
export class AppComponent {

    swipeAll(event: any): any {
        console.log('Swipe All', event);
    }

    swipeLeft(event: any): any {
        console.log('Swipe Left', event);
    }

    swipeRight(event: any): any {
        console.log('Swipe Right', event);
    }

    swipeUp(event: any): any {
        console.log('Swipe Up', event);
    }

    swipeDown(event: any): any {
        console.log('Swipe Down', event);
    }

}

Keywords

FAQs

Package last updated on 17 Oct 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