Created
June 29, 2015 13:44
-
-
Save russweas/54f64f2e779f5bbca1ed to your computer and use it in GitHub Desktop.
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
// app.js call method. | |
call: function(view, name, args = []) { | |
if(this.viewData[view].ready == true) { | |
this.viewData[view].model[name](args); | |
} else { | |
this.viewData[view].funcs_to_call.push({name: name, args: args}); | |
} | |
} | |
// updated for loop inside each view | |
for(var i in methods) | |
{ | |
this[methods[i].name](methods[i].args); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment