#29 Add Keyboard Shortcuts

Tip

What if you want your app to submit a form when you hit Ctrl-Enter or perform a search when you hit some other key combo?  You can easily do that with the ember-keyboard addon.
Install the addon with
ember install ember-keyboard

Import the mixin into your component

Activate the keyboard listeners

Wire up your keyboard combo

Bonus Tip:
You can see all the different key names over here.

Credits & Links

ember-keyboard @ https://github.com/null-null-null/ember-keyboard
documentation @ http://null-null-null.github.io/ember-keyboard
Thanks to Ember Weekly for mentioning this.

Some Love ❤❤❤

If you are enjoying my daily tips please spread the word with this one-click tweet.
If you do NOT like the tips then please reply to this email and let me know.

Published by

Emad Ibrahim

Author of asp .net MVC & TDD, entrepreneur, passionate technologist, programmer and productivity nut. more at http://t.co/oSJXPvzu