Created
November 26, 2013 01:09
-
-
Save meowsus/7651809 to your computer and use it in GitHub Desktop.
Refactor me plz
This file contains hidden or 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
| eventListener = function (widget) { | |
| widget.$postalCode.one('focus', function () { | |
| applyValidationRules(widget); | |
| }); | |
| widget.$country.on('change', function () { | |
| applyValidationRules(widget); | |
| }); | |
| widget.$parentForm.on('submit', function () { | |
| applyValidationRules(widget); | |
| }); | |
| }, |
imbcmdth
commented
Nov 26, 2013
eventListener=function(w){
(function(o,f){for(k in o)f(k,o[k]);})(
{'focus':w.$postalCode.one,'change':w.$country.on,'submit':w.$parentForm.on},
function(k,v){v.call(k,applyValidationRules(w))});
},
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment