Socket
Socket
Sign inDemoInstall

swipe-direction

Package Overview
Dependencies
4
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    swipe-direction

detect direction swipe of an element on web mobile


Version published
Weekly downloads
0
Maintainers
1
Install size
313 kB
Created
Weekly downloads
 

Readme

Source

Note

This package is for use in mobile devices that works with touch screen (web mobile). The package permit identify the direction swipe

How to use

Install: npm install swipe-direction

Usage: . . .

import useSwipeDetector from "swipe-direction";

const SwapContainer = () => {
  const [moveTo, events] = useSwipeDetector();
  return (
    <div className="grid">
      <div {...events} className="box-detector">
        <h1 className="text"> {moveTo} </h1>
      </div>
    </div>
  );
};

this code show a element where you can do swipe and it show to the direction on screen

Keywords

FAQs

Last updated on 04 Mar 2022

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc