Authorization solution

I’m building a social app with Firebase as a backend and I find myself coding the entire authorization flow (registration, login, logout, forgot password, session management, user management, profile management, remove account) from scratch.
I’m kind of new with AngularJS so finding examples which include Ionic/Angular/Firebase is not easy task and although I found good samples, I don’t think they are good enough for production.
Is there a project I can reuse to get me started quickly?
How do you guys do this, you code the UI logic from scratch?



do you already use AngularFire? Firebase changed, the former SimpleLogin lib is now integrated in Firebase core, usage and functions changed. AngularFire is catching up with the upcoming 0.9.1 release.

We use the routes definition of ui-router to define authentication and authorization using the data property like data: {access: public}. This way you can hook up your logic into every state transition using $stateChangeStart and define the top views only or have fine-grained access control.

See also