Skip to content

Commit

Permalink
Add 'deleteScope' Method to Readme
Browse files Browse the repository at this point in the history
I've noticed in the project source that there is a very useful `deleteScope` method for removing all events bound in a scope. 

I was struggling with keeping track of each bound key separately and found that this saves me a bit of time. 

Perhaps we can include in the docs so others can find this functionality more easily?
  • Loading branch information
jlukic committed Apr 21, 2016
1 parent f561f38 commit 3eb1da2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,10 @@ key('o, enter', 'files', function(){ /* do something else */ });

// set the scope (only 'all' and 'issues' shortcuts will be honored)
key.setScope('issues'); // default scope is 'all'

// remove all events that are set in 'issues' scope
key.deleteScope('issues');

```


Expand Down

0 comments on commit 3eb1da2

Please sign in to comment.