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
import {Injectable} from "@angular/core"; | |
import { Observable } from 'rxjs/Observable'; | |
import { FirebaseObjectFactoryOpts } from "angularfire2/interfaces"; | |
import { AngularFireDatabaseModule, AngularFireDatabase, FirebaseListObservable, FirebaseObjectObservable } from 'angularfire2/database'; | |
import { AngularFireAuthModule, AngularFireAuth } from 'angularfire2/auth'; | |
import * as firebase from 'firebase/app'; | |
import { Headers, Http, RequestOptions } from '@angular/http'; | |
import 'rxjs/add/operator/toPromise'; | |
@Injectable() |
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
... | |
<h2>Example 1</h2> | |
<button (click)="createNewUserHit($event)">Create a user via backend</button> | |
<button (click)="signInEmailPassHit($event)">Sign in using email and pass</button> | |
... |
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
import { Component } from '@angular/core'; | |
import { AngularFireDatabase, FirebaseListObservable } from 'angularfire2/database'; | |
import { AF } from '../providers/af'; | |
import { HttpModule } from '@angular/http'; | |
import { Observable } from 'rxjs/Observable'; | |
import { AngularFireAuthModule, AngularFireAuth } from 'angularfire2/auth'; | |
@Component({ | |
selector: 'app-root', | |
templateUrl: './app.component.html', |
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
import { Component } from '@angular/core'; | |
import { AngularFireDatabase, FirebaseListObservable } from 'angularfire2/database'; | |
import { AF } from '../providers/af'; | |
import { HttpModule } from '@angular/http'; | |
import { Observable } from 'rxjs/Observable'; | |
import { AngularFireAuthModule, AngularFireAuth } from 'angularfire2/auth'; | |
@Component({ | |
selector: 'app-root', | |
templateUrl: './app.component.html', |
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
import { BrowserModule } from '@angular/platform-browser'; | |
import { NgModule } from '@angular/core'; | |
import { FormsModule } from '@angular/forms'; | |
import { HttpModule } from '@angular/http'; | |
import { AppComponent } from './app.component'; | |
import { AngularFireModule } from 'angularfire2'; | |
import { AngularFireDatabaseModule } from 'angularfire2/database'; | |
import { AngularFireAuthModule } from 'angularfire2/auth'; | |
import { environment } from '../environments/environment'; | |
import { RegisterComponent } from './register/register.component'; |
NewerOlder