Created
January 3, 2018 00:52
-
-
Save kangwa/35dd03f38988f60c1015f3d832ea4ed5 to your computer and use it in GitHub Desktop.
NativeScript AccountKit ViewModel
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
function createViewModel() { | |
var viewModel = new Observable(); | |
viewModel.phoneLogin = function () { | |
var phoneLoginType = com.facebook.accountkit.ui.LoginType.PHONE; | |
accountKitLogin(phoneLoginType) | |
} | |
viewModel.emailLogin = function () { | |
var emailLoginType = com.facebook.accountkit.ui.LoginType.EMAIL; | |
accountKitLogin(emailLoginType) | |
} | |
return viewModel; | |
} | |
exports.createViewModel = createViewModel; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment