Last active
December 12, 2015 07:52
-
-
Save ruz/42d5e1be42ab56f744d7 to your computer and use it in GitHub Desktop.
prevent form submit on enter key
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName:'Ember Twiddle', | |
actions: { | |
prevent(e) { | |
console.log("here we are"); | |
e.preventDefault(); | |
return false; | |
}, | |
}, | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.4.16", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "2.1.0", | |
"ember-data": "2.1.0", | |
"ember-template-compiler": "2.1.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment