Created
July 11, 2011 15:11
-
-
Save tsloughter/1076056 to your computer and use it in GitHub Desktop.
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
class @viewModel | |
firstname : ko.observable "" | |
lastname : ko.observable "" | |
email : ko.observable "" | |
username : ko.observable "" | |
password : ko.observable "" | |
save : -> | |
$.post '/user', ko.toJSON(this), (data) -> $('body').append "Successfully created user." | |
viewmodel = new viewModel | |
ko.applyBindings viewmodel |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment