Skip to content

Instantly share code, notes, and snippets.

@jxm262
Created July 25, 2015 22:34
Show Gist options
  • Save jxm262/65af9614e16b4e372a77 to your computer and use it in GitHub Desktop.
Save jxm262/65af9614e16b4e372a77 to your computer and use it in GitHub Desktop.
var mySubmitFunc = function(error, state){
if (!error) {
if (state === "signIn") {
console.log('signed in...');
// Successfully logged in
// ...
}
if (state === "signUp") {
console.log('signed up...');
// Successfully registered
// ...
}
}
};
//Routes
AccountsTemplates.configureRoute('changePwd');
AccountsTemplates.configureRoute('enrollAccount');
AccountsTemplates.configureRoute('forgotPwd');
AccountsTemplates.configureRoute('resetPwd');
AccountsTemplates.configureRoute('signIn');
AccountsTemplates.configureRoute('signUp');
AccountsTemplates.configureRoute('verifyEmail');
// Options
AccountsTemplates.configure({
//defaultLayout: 'emptyLayout',
showForgotPasswordLink: true,
overrideLoginErrors: true,
enablePasswordChange: true,
sendVerificationEmail: false,
homeRoutePath: '/',
redirectTimeout: 4000,
//enforceEmailVerification: true,
//confirmPassword: true,
//continuousValidation: false,
//displayFormLabels: true,
//forbidClientAccountCreation: false,
//formValidationFeedback: true,
//homeRoutePath: '/',
//showAddRemoveServices: false,
//showPlaceholders: true,
negativeValidation: true,
positiveValidation:true,
negativeFeedback: false,
positiveFeedback:true,
// Privacy Policy and Terms of Use
//privacyUrl: 'privacy',
//termsUrl: 'terms-of-use',
onSubmitHook: mySubmitFunc
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment