An open API service indexing awesome lists of open source software.

https://github.com/ulivz/get-event-listeners

An event interceptor allowing you to get all the event listeners of an element
https://github.com/ulivz/get-event-listeners

Last synced: 6 months ago
JSON representation

An event interceptor allowing you to get all the event listeners of an element

Awesome Lists containing this project

README

          

# @ulivz/get-event-listeners

[![NPM version](https://badgen.net/npm/v/@ulivz/get-event-listeners)](https://npmjs.com/package/@ulivz/get-event-listeners) [![NPM downloads](https://badgen.net/npm/dm/@ulivz/get-event-listeners)](https://npmjs.com/package/@ulivz/get-event-listeners)

## Usage

In order to capture all the events, you need to introduce this script in the head of your HTML:

- From CDN:

```html

```

- From local file:

```html
<script src="./get-event-listeners.min.js">
```

## API

### getEventListeners(HTMLElement)

Get event listenrs of a particular element

### getAllEventListeners()

Get event listenrs of all elements

## Contributing

1. Fork it!
2. Create your feature branch: `git checkout -b my-new-feature`
3. Commit your changes: `git commit -am 'Add some feature'`
4. Push to the branch: `git push origin my-new-feature`
5. Submit a pull request :D

## Author

**@ulivz/get-event-listeners** © [ULIVZ](https://github.com/ulivz), Released under the [MIT](./LICENSE) License.<br>
Authored and maintained by ULIVZ with help from contributors ([list](https://github.com/ulivz/get-event-listeners/contributors)).

> [github.com/ulivz](https://github.com/ulivz) · GitHub [@ULIVZ](https://github.com/ulivz) · Twitter [@_ulivz](https://twitter.com/_ulivz)