Double Click Event Listener for JavaScript

Adds an Event Listener that listens for both click and double click.

How to use

Add double-click.js file to your project and link it on html file.

Instructions

addDoubleClickListener has four Arguments:

element : html element that you want to add evnet listener to.

onClick : a function that executes when user clicks ONCE.

onDoubleClick : a function that executes when user clicks TWICE.

doubleClickDelay_MS : the delay between clicks that when user clicks again on that duration, system takes that as Double Click.

Check out the example.js