Socket
Socket
Sign inDemoInstall

lesca-click

Package Overview
Dependencies
3
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    lesca-click

use for prevent browser default behavior. usually used in web without scroll app.


Version published
Weekly downloads
1
decreased by-90.91%
Maintainers
1
Install size
754 kB
Created
Weekly downloads
 

Readme

Source

React React React React React NPM React NPM

Why use it?

use for prevent browser default behavior. usually used in web without scroll app.

Installation

$ npm install lesca-click --save

Demo

Live Demo

Usage

import Click from 'lesca-click';

Click.install();

Click.add('.target', (e) => {
  console.log('target clicked');
});

// find single className only
<div class='target'> // good
<div class='target on'> // bed

Methods

methodoptionstypedescriptiondefault
.install()installtrue
add(target, execution)targetstringselector => ".target" or "#target"
executionfunctioncall when target clicked
remove(target)targetstringselector => ".target" or "#target"
clear()clear all functions
setPreventDefault(value)valuebooleanset preventDefault enable or disable
addPreventExcept(target)targetstring".target" or "#target"

Features

  • maintain if necessary

Keywords

FAQs

Last updated on 17 Oct 2023

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