aboutsummaryrefslogtreecommitdiff
path: root/node_modules/delegate/readme.md
diff options
context:
space:
mode:
authorruki <waruqi@gmail.com>2018-11-08 00:43:05 +0800
committerruki <waruqi@gmail.com>2018-11-07 22:18:30 +0800
commit89e95b3f143682ed9a006991bacf45c9dcba4818 (patch)
tree4f44cf41b828577d583890bdd5a1c31e8491a6ba /node_modules/delegate/readme.md
parentaa7f0199255277949790b41c56e8ec97dd4f0da4 (diff)
downloadxmake-docs-vuepress.tar.gz
xmake-docs-vuepress.zip
remove node_modulesvuepress
Diffstat (limited to 'node_modules/delegate/readme.md')
-rw-r--r--node_modules/delegate/readme.md99
1 files changed, 0 insertions, 99 deletions
diff --git a/node_modules/delegate/readme.md b/node_modules/delegate/readme.md
deleted file mode 100644
index cae433a4..00000000
--- a/node_modules/delegate/readme.md
+++ /dev/null
@@ -1,99 +0,0 @@
-# delegate
-
-Lightweight event delegation.
-
-## Install
-
-You can get it on npm.
-
-```
-npm install delegate --save
-```
-
-If you're not into package management, just [download a ZIP](https://github.com/zenorocha/delegate/archive/master.zip) file.
-
-## Setup
-
-###### Node (Browserify)
-
-```js
-var delegate = require('delegate');
-```
-
-###### Browser (Standalone)
-
-```html
-<script src="dist/delegate.js"></script>
-```
-
-## Usage
-
-### Add event delegation
-
-#### With the default base (`document`)
-
-```js
-delegate('.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-```
-
-#### With an element as base
-
-```js
-delegate(document.body, '.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-```
-
-#### With a selector (of existing elements) as base
-
-```js
-delegate('.container', '.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-```
-
-#### With an array/array-like of elements as base
-
-```js
-delegate(document.querySelectorAll('.container'), '.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-```
-
-### Remove event delegation
-
-#### With a single base element (default or specified)
-
-```js
-var delegation = delegate(document.body, '.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-
-delegation.destroy();
-```
-
-#### With multiple elements (via selector or array)
-
-Note: selectors are always treated as multiple elements, even if one or none are matched. `delegate()` will return an array.
-
-```js
-var delegations = delegate('.container', '.btn', 'click', function(e) {
- console.log(e.delegateTarget);
-}, false);
-
-delegations.forEach(function (delegation) {
- delegation.destroy();
-});
-```
-
-## Browser Support
-
-| <img src="https://clipboardjs.com/assets/images/chrome.png" width="48px" height="48px" alt="Chrome logo"> | <img src="https://clipboardjs.com/assets/images/edge.png" width="48px" height="48px" alt="Edge logo"> | <img src="https://clipboardjs.com/assets/images/firefox.png" width="48px" height="48px" alt="Firefox logo"> | <img src="https://clipboardjs.com/assets/images/ie.png" width="48px" height="48px" alt="Internet Explorer logo"> | <img src="https://clipboardjs.com/assets/images/opera.png" width="48px" height="48px" alt="Opera logo"> | <img src="https://clipboardjs.com/assets/images/safari.png" width="48px" height="48px" alt="Safari logo"> |
-|:---:|:---:|:---:|:---:|:---:|:---:|
-| Latest ✔ | Latest ✔ | Latest ✔ | 9+ ✔ | Latest ✔ | Latest ✔ |
-
-## License
-
-[MIT License](http://zenorocha.mit-license.org/) © Zeno Rocha