Git Product home page Git Product logo

angularfire-login-boilerplate's Introduction

angularfire-login-boilerplate

A simple template for getting started with AngularFire (AngularJS + Firebase) w/ user login system.

This tutorial will show you how to set up a simple email/password-based user authentication system using AngularFire, along with a corresponding table for persistence of user data.

Getting Started

First, you will need to sign up at Firebase. The free plan they offer includes 5GB of data transfer, 50 max connections, and 100MB of data storage (as of 10/20/2013).

Once you have signed up, go to your Account Page to create a new Firebase. Choose a unique name and click Create, and once it appears, click Edit. This will bring you to your new Firebase's data editing screen.

Paste this JSON into a file and save it:

{ "users" : [ null, { "name" : { "last" : "Simpson", "first" : "Homer" } } ] }

Click Import JSON and choose the file to set yourself up as the first user.

Next, click on Auth, and under Authentication Providers, click on Email & Password. Click the checkbox to Enable email / password authentication in your application. Then, under Add New User, enter your email address and a password to create yourself. Your User ID should be 1.

Once you have created your user, click on Security and paste this in for the rules, then click Save Rules:

{ "rules": { "users": { "$userid": { ".read": "auth.id == $userid", ".write": "auth.id == $userid" } } } }

This will restrict the ability to read/write data to only the logged-in user.

Your Firebase user login + data system is now ready to go! Upload the boilerplate files to your web host, making sure to update js/controllers.js (line 9) with the correct URL to your Firebase.

Demo

http://www.malenczak.com/angularfire-login-boilerplate/

angularfire-login-boilerplate's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

angularfire-login-boilerplate's Issues

Compatibility Update

When I have more time I may come back a do this....

This project uses Firebases old auth service (angularFireAuth) and should be updated to the latest libraries: AngularFire and Simple Login service.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.